diff --git a/src/renderer/components/ft-toggle-switch/ft-toggle-switch.css b/src/renderer/components/ft-toggle-switch/ft-toggle-switch.css
new file mode 100644
index 00000000..1d57aaf0
--- /dev/null
+++ b/src/renderer/components/ft-toggle-switch/ft-toggle-switch.css
@@ -0,0 +1,74 @@
+/* Thanks to Guus Lieben for the Material Design Switch */
+
+.switch-input {
+ display: none;
+}
+
+.switch-label {
+ position: relative;
+ display: inline-block;
+ min-width: 112px;
+ cursor: pointer;
+ font-weight: 500;
+ text-align: left;
+ margin: 16px;
+ padding: 16px 0 16px 44px;
+}
+
+.switch-label:before,
+.switch-label:after {
+ content: "";
+ position: absolute;
+ margin: 0;
+ outline: 0;
+ top: 50%;
+ -ms-transform: translate(0, -50%);
+ -webkit-transform: translate(0, -50%);
+ transform: translate(0, -50%);
+ -webkit-transition: all 0.3s ease;
+ transition: all 0.3s ease;
+}
+
+.switch-label:before {
+ left: 1px;
+ width: 34px;
+ height: 14px;
+ background-color: #9E9E9E;
+ border-radius: 8px;
+}
+
+.switch-label:after {
+ left: 0;
+ width: 20px;
+ height: 20px;
+ background-color: #FAFAFA;
+ border-radius: 50%;
+ box-shadow: 0 3px 1px -2px rgba(0, 0, 0, 0.14), 0 2px 2px 0 rgba(0, 0, 0, 0.098), 0 1px 5px 0 rgba(0, 0, 0, 0.084);
+}
+
+.switch-label .toggle--on {
+ display: none;
+}
+
+.switch-label .toggle--off {
+ display: inline-block;
+}
+
+.switch-input:checked+.switch-label:before {
+ background-color: #90CAF9;
+}
+
+.switch-input:checked+.switch-label:after {
+ background-color: #2196F3;
+ -ms-transform: translate(80%, -50%);
+ -webkit-transform: translate(80%, -50%);
+ transform: translate(80%, -50%);
+}
+
+.switch-input:checked+.switch-label .toggle--on {
+ display: inline-block;
+}
+
+.switch-input:checked+.switch-label .toggle--off {
+ display: none;
+}
diff --git a/src/renderer/components/ft-toggle-switch/ft-toggle-switch.js b/src/renderer/components/ft-toggle-switch/ft-toggle-switch.js
new file mode 100644
index 00000000..5439c5d9
--- /dev/null
+++ b/src/renderer/components/ft-toggle-switch/ft-toggle-switch.js
@@ -0,0 +1,25 @@
+import Vue from 'vue'
+
+export default Vue.extend({
+ name: 'FtToggleSwitch',
+ props: {
+ label: {
+ type: String,
+ required: true
+ },
+ defaultValue: {
+ type: Boolean,
+ default: false
+ }
+ },
+ data: function () {
+ return {
+ id: '',
+ currentValue: false
+ }
+ },
+ mounted: function () {
+ this.id = this._uid
+ this.currentValue = this.defaultValue
+ }
+})
diff --git a/src/renderer/components/ft-toggle-switch/ft-toggle-switch.vue b/src/renderer/components/ft-toggle-switch/ft-toggle-switch.vue
new file mode 100644
index 00000000..b9545c47
--- /dev/null
+++ b/src/renderer/components/ft-toggle-switch/ft-toggle-switch.vue
@@ -0,0 +1,22 @@
+
+
+
+
+
+
+
+
+
diff --git a/src/renderer/components/general-settings/general-settings.css b/src/renderer/components/general-settings/general-settings.css
new file mode 100644
index 00000000..f834bf68
--- /dev/null
+++ b/src/renderer/components/general-settings/general-settings.css
@@ -0,0 +1,9 @@
+.relative {
+ position: relative;
+}
+
+.card {
+ width: 85%;
+ margin: 0 auto;
+ margin-bottom: 60px;
+}
diff --git a/src/renderer/components/general-settings/general-settings.js b/src/renderer/components/general-settings/general-settings.js
new file mode 100644
index 00000000..b36e7079
--- /dev/null
+++ b/src/renderer/components/general-settings/general-settings.js
@@ -0,0 +1,552 @@
+import Vue from 'vue'
+import FtCard from '../ft-card/ft-card.vue'
+import FtSelect from '../ft-select/ft-select.vue'
+import FtToggleSwitch from '../ft-toggle-switch/ft-toggle-switch.vue'
+import FtFlexBox from '../ft-flex-box/ft-flex-box.vue'
+
+export default Vue.extend({
+ name: 'GeneralSettings',
+ components: {
+ 'ft-card': FtCard,
+ 'ft-select': FtSelect,
+ 'ft-toggle-switch': FtToggleSwitch,
+ 'ft-flex-box': FtFlexBox
+ },
+ data: function () {
+ return {
+ title: 'General Settings',
+ themeNames: [
+ 'Light Red',
+ 'Dark Red',
+ 'Gray Red'
+ ],
+ themeValues: [
+ 'lightRed',
+ 'darkRed',
+ 'grayRed'
+ ],
+ backendNames: [
+ 'Invidious API',
+ 'Local API'
+ ],
+ backendValues: [
+ 'invidious',
+ 'local'
+ ],
+ defaultPageNames: [
+ 'Subscriptions',
+ 'Trending',
+ 'Most Popular',
+ 'Playlists',
+ 'History'
+ ],
+ defaultPageValues: [
+ 'subscriptions',
+ 'trending',
+ 'mostPopular',
+ 'playlists',
+ 'history'
+ ],
+ viewTypeNames: [
+ 'Grid',
+ 'List'
+ ],
+ viewTypeValues: [
+ 'grid',
+ 'list'
+ ],
+ regionNames: [
+ 'Afghanistan',
+ 'Albania',
+ 'Algeria',
+ 'American Samoa',
+ 'Andorra',
+ 'Angola',
+ 'Antarctica',
+ 'Antigua And Barbuda',
+ 'Argentina',
+ 'Armenia',
+ 'Aruba',
+ 'Australia',
+ 'Austria',
+ 'Azerbaijan',
+ 'Bahamas',
+ 'Bahrain',
+ 'Bangladesh',
+ 'Barbados',
+ 'Belarus',
+ 'Belgium',
+ 'Belize',
+ 'Benin',
+ 'Bermuda',
+ 'Bhutan',
+ 'Bolivia',
+ 'Bosnia And Herzegovina',
+ 'Botswana',
+ 'Bouvet Island',
+ 'Brazil',
+ 'British Indian Ocean Territory',
+ 'Brunei Darussalam',
+ 'Bulgaria',
+ 'Burkina Faso',
+ 'Burundi',
+ 'Cambodia',
+ 'Cameroon',
+ 'Canada',
+ 'Cape Verde',
+ 'Cayman Islands',
+ 'Central African Republic',
+ 'Chad',
+ 'Chile',
+ 'China',
+ 'Christmas Island',
+ 'Cocos (Keeling) Islands',
+ 'Colombia',
+ 'Comoros',
+ 'Congo',
+ 'Congo, The Democratic Republic Of The',
+ 'Cook Islands',
+ 'Costa Rica',
+ "Cote D'Ivoire",
+ 'Croatia',
+ 'Cuba',
+ 'Cyprus',
+ 'Czech Republic',
+ 'Denmark',
+ 'Djibouti',
+ 'Dominica',
+ 'Dominican Republic',
+ 'Ecuador',
+ 'Egypt',
+ 'El Salvador',
+ 'Equatorial Guinea',
+ 'Eritrea',
+ 'Estonia',
+ 'Ethiopia',
+ 'Falkland Islands (Malvinas)',
+ 'Faroe Islands',
+ 'Fiji',
+ 'Finland',
+ 'France',
+ 'French Guiana',
+ 'French Polynesia',
+ 'French Southern Territories',
+ 'Gabon',
+ 'Gambia',
+ 'Georgia',
+ 'Germany',
+ 'Ghana',
+ 'Gibraltar',
+ 'Greece',
+ 'Greenland',
+ 'Grenada',
+ 'Guadeloupe',
+ 'Guam',
+ 'Guatamala',
+ 'Guinea',
+ 'Guinea-Bissau',
+ 'Guyana',
+ 'Haiti',
+ 'Heard Island And McDonald Islands',
+ 'Honduras',
+ 'Hong Kong',
+ 'Hungary',
+ 'Iceland',
+ 'India',
+ 'Indonesia',
+ 'Iran, Islamic Republic Of',
+ 'Iraq',
+ 'Ireland',
+ 'Israel',
+ 'Italy',
+ 'Jamaica',
+ 'Japan',
+ 'Jordan',
+ 'Kazakhstan',
+ 'Kenya',
+ 'Kiribati',
+ "Korea, Democratic People's Republic Of",
+ 'Korea, Republic Of',
+ 'Kuwait',
+ 'Kyrgyzstan',
+ "Lao People's Democratic Republic (LAOS)",
+ 'Latvia',
+ 'Lebonon',
+ 'Lesotho',
+ 'Liberia',
+ 'Libyan Arab Jamahiriya',
+ 'Liechtenstein',
+ 'Lithuania',
+ 'Luxembourg',
+ 'Macao',
+ 'Macedonia, The Former Yugoslav Republic Of',
+ 'Madagascar',
+ 'Malawi',
+ 'Malaysia',
+ 'Maldives',
+ 'Mali',
+ 'Malta',
+ 'Marshall Islands',
+ 'Martinique',
+ 'Mauritania',
+ 'Mauritius',
+ 'Mayotte',
+ 'Mexico',
+ 'Micronesia, Federated States Of',
+ 'Moldova, Republic Of',
+ 'Monaco',
+ 'Mongolia',
+ 'Montenegro',
+ 'Montserrat',
+ 'Morocco',
+ 'Mozambique',
+ 'Myanmar',
+ 'Namibia',
+ 'Nauru',
+ 'Nepal',
+ 'Netherlands',
+ 'Netherlands Antilles',
+ 'New Caledonia',
+ 'New Zealand',
+ 'Nicaragua',
+ 'Niger',
+ 'Nigeria',
+ 'Niue',
+ 'Norfolk Island',
+ 'Northern Mariana Islands',
+ 'Norway',
+ 'Oman',
+ 'Pakistan',
+ 'Palau',
+ 'Palestinian Territory, Occupied',
+ 'Panama',
+ 'Papua New Guinea',
+ 'Paraguay',
+ 'Peru',
+ 'Philippines',
+ 'Pitcair',
+ 'Poland',
+ 'Portugal',
+ 'Puerto Rico',
+ 'Qatar',
+ 'Reunion',
+ 'Romania',
+ 'Russian Federation',
+ 'Rwanda',
+ 'Saint Helena',
+ 'Saint Kitts And Nevis',
+ 'Saint Lucia',
+ 'Saint Pierre And Miquelon',
+ 'Saint Vincent And The Grenadines',
+ 'Samoa',
+ 'San Marina',
+ 'Sao Tome And Principe',
+ 'Saudi Arabia',
+ 'Senegal',
+ 'Serbia',
+ 'Seychelles',
+ 'Sierra Leone',
+ 'Singapore',
+ 'Slovakia',
+ 'Slovenia',
+ 'Solomon Islands',
+ 'Somalia',
+ 'South Africa',
+ 'South Georgia And The South Sandwich Islands',
+ 'Spain',
+ 'Sri Lanka',
+ 'Sudan',
+ 'Suriname',
+ 'Svalbard And Jan Mayen',
+ 'Swaziland',
+ 'Sweden',
+ 'Switzerland',
+ 'Syrian Arab Republic',
+ 'Taiwan',
+ 'Tajikistan',
+ 'Tanzania, United Republic Of',
+ 'Thailand',
+ 'Timor-Leste',
+ 'Togo',
+ 'Tokelau',
+ 'Tonga',
+ 'Trinidad And Tobago',
+ 'Tunisia',
+ 'Turkey',
+ 'Turkenistan',
+ 'Turks And Caicos Islands',
+ 'Tuvalu',
+ 'Uganda',
+ 'Ukraine',
+ 'United Arab Emirates',
+ 'United Kingdom',
+ 'United States',
+ 'United States Minor Outlying Islands',
+ 'Uruguay',
+ 'Uzbekistan',
+ 'Vanuatu',
+ 'Venezuela',
+ 'Viet Nam',
+ 'Virgin Islands, British',
+ 'Virgin Islands, U.S.',
+ 'Wallis And Futuna',
+ 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ted: function () {
+ },
+ methods: {
+ goToChannel: function () {
+ console.log('TODO: Handle goToChannel')
+ }
+ }
+})
diff --git a/src/renderer/components/general-settings/general-settings.vue b/src/renderer/components/general-settings/general-settings.vue
new file mode 100644
index 00000000..c3e5de6e
--- /dev/null
+++ b/src/renderer/components/general-settings/general-settings.vue
@@ -0,0 +1,54 @@
+
+
+
+ {{ title }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/renderer/components/player-settings/player-settings.css b/src/renderer/components/player-settings/player-settings.css
new file mode 100644
index 00000000..f834bf68
--- /dev/null
+++ b/src/renderer/components/player-settings/player-settings.css
@@ -0,0 +1,9 @@
+.relative {
+ position: relative;
+}
+
+.card {
+ width: 85%;
+ margin: 0 auto;
+ margin-bottom: 60px;
+}
diff --git a/src/renderer/components/player-settings/player-settings.js b/src/renderer/components/player-settings/player-settings.js
new file mode 100644
index 00000000..e73e4caa
--- /dev/null
+++ b/src/renderer/components/player-settings/player-settings.js
@@ -0,0 +1,66 @@
+import Vue from 'vue'
+import FtCard from '../ft-card/ft-card.vue'
+import FtSelect from '../ft-select/ft-select.vue'
+import FtToggleSwitch from '../ft-toggle-switch/ft-toggle-switch.vue'
+import FtFlexBox from '../ft-flex-box/ft-flex-box.vue'
+
+export default Vue.extend({
+ name: 'PlayerSettings',
+ components: {
+ 'ft-card': FtCard,
+ 'ft-select': FtSelect,
+ 'ft-toggle-switch': FtToggleSwitch,
+ 'ft-flex-box': FtFlexBox
+ },
+ data: function () {
+ return {
+ title: 'Player Settings',
+ formatNames: [
+ 'Dash Formats',
+ 'Legacy Formats',
+ 'YouTube Player'
+ ],
+ formatValues: [
+ 'dash',
+ 'legacy',
+ 'youtube'
+ ],
+ qualityNames: [
+ 'Auto',
+ '144p',
+ '240p',
+ '360p',
+ '480p',
+ '720p',
+ '1080p',
+ '1440p',
+ '4k',
+ '8k'
+ ],
+ qualityValues: [
+ 'auto',
+ '144',
+ '240',
+ '360',
+ '480',
+ '720',
+ '1080',
+ '1440',
+ '4k',
+ '8k'
+ ]
+ }
+ },
+ computed: {
+ invidiousInstance: function () {
+ return this.$store.getters.getInvidiousInstance
+ }
+ },
+ mounted: function () {
+ },
+ methods: {
+ goToChannel: function () {
+ console.log('TODO: Handle goToChannel')
+ }
+ }
+})
diff --git a/src/renderer/components/player-settings/player-settings.vue b/src/renderer/components/player-settings/player-settings.vue
new file mode 100644
index 00000000..10aab431
--- /dev/null
+++ b/src/renderer/components/player-settings/player-settings.vue
@@ -0,0 +1,51 @@
+
+
+
+ {{ title }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/renderer/views/Settings/Settings.js b/src/renderer/views/Settings/Settings.js
index 7266d273..4b953d52 100644
--- a/src/renderer/views/Settings/Settings.js
+++ b/src/renderer/views/Settings/Settings.js
@@ -1,13 +1,22 @@
import Vue from 'vue'
import FtCard from '../../components/ft-card/ft-card.vue'
import FtElementList from '../../components/ft-element-list/ft-element-list.vue'
+import GeneralSettings from '../../components/general-settings/general-settings.vue'
+import PlayerSettings from '../../components/player-settings/player-settings.vue'
export default Vue.extend({
name: 'Settings',
components: {
'ft-card': FtCard,
- 'ft-element-list': FtElementList
+ 'ft-element-list': FtElementList,
+ 'general-settings': GeneralSettings,
+ 'player-settings': PlayerSettings
},
mounted: function () {
+ },
+ methods: {
+ handleToggleSwitch: function (event) {
+ console.log(event)
+ }
}
})
diff --git a/src/renderer/views/Settings/Settings.vue b/src/renderer/views/Settings/Settings.vue
index 4e75b66a..f7190632 100644
--- a/src/renderer/views/Settings/Settings.vue
+++ b/src/renderer/views/Settings/Settings.vue
@@ -1,8 +1,7 @@