Skip to content

Commit 918b0ff

Browse files
committed
Merge branch 'development' of https://github.com/FreeTubeApp/FreeTube into fix-blog-notification
2 parents 7f654ff + 78cf02a commit 918b0ff

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

71 files changed

+2560
-781
lines changed

.github/ISSUE_TEMPLATE/bug_report.yaml

Lines changed: 13 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -75,24 +75,24 @@ body:
7575
required: true
7676
- type: dropdown
7777
attributes:
78-
label: 'Installation Method (If applicable)'
78+
label: Installation Method
7979
options:
80+
- .apk
8081
- .AppImage
82+
- AUR
83+
- Chocolatey
8184
- .deb
8285
- .dmg
8386
- .exe
8487
- Flathub
88+
- .pacman
8589
- Portable
8690
- .rpm
91+
- winget
8792
- .zip
8893
- other
8994
validations:
90-
required: false
91-
- type: input
92-
attributes:
93-
label: 'Last Known Working FreeTube Version (If Any)'
94-
description: What is the last version of FreeTube this worked in, if applicable?
95-
placeholder: v0.14.0
95+
required: true
9696
- type: dropdown
9797
attributes:
9898
label: Primary API used
@@ -102,7 +102,12 @@ body:
102102
- Local API
103103
- Invidious API
104104
validations:
105-
required: false
105+
required: true
106+
- type: input
107+
attributes:
108+
label: 'Last Known Working FreeTube Version (If Any)'
109+
description: What is the last version of FreeTube this worked in, if applicable?
110+
placeholder: v0.14.0
106111
- type: textarea
107112
attributes:
108113
label: Additional Information

package.json

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "freetube",
33
"productName": "FreeTube",
44
"description": "A private YouTube client",
5-
"version": "0.16.0",
5+
"version": "0.17.0",
66
"license": "AGPL-3.0-or-later",
77
"main": "./dist/main.js",
88
"private": true,
@@ -60,9 +60,7 @@
6060
"js-yaml": "^4.1.0",
6161
"lodash.debounce": "^4.0.8",
6262
"lodash.isequal": "^4.5.0",
63-
"lodash.uniqwith": "^4.5.0",
64-
"marked": "^4.0.15",
65-
"material-design-icons": "^3.0.1",
63+
"marked": "^4.0.17",
6664
"nedb-promises": "^5.0.1",
6765
"opml-to-json": "^1.0.1",
6866
"rss-parser": "^3.12.0",
@@ -71,10 +69,8 @@
7169
"videojs-contrib-quality-levels": "^2.1.0",
7270
"videojs-http-source-selector": "^1.1.6",
7371
"videojs-overlay": "^2.1.4",
74-
"videojs-replay": "^1.1.0",
7572
"videojs-vtt-thumbnails-freetube": "0.0.15",
7673
"vue": "^2.6.14",
77-
"vue-electron": "^1.0.6",
7874
"vue-i18n": "^8.25.0",
7975
"vue-observe-visibility": "^1.0.0",
8076
"vue-router": "^3.5.2",
@@ -96,7 +92,7 @@
9692
"copy-webpack-plugin": "^9.0.1",
9793
"css-loader": "5.2.6",
9894
"electron": "^16.2.7",
99-
"electron-builder": "^22.11.7",
95+
"electron-builder": "^23.0.3",
10096
"electron-builder-squirrel-windows": "^22.13.1",
10197
"electron-debug": "^3.2.0",
10298
"eslint": "^7.32.0",
@@ -108,11 +104,9 @@
108104
"eslint-plugin-promise": "^5.1.0",
109105
"eslint-plugin-standard": "^5.0.0",
110106
"eslint-plugin-vue": "^7.17.0",
111-
"fast-glob": "^3.2.7",
112107
"file-loader": "^6.2.0",
113108
"html-webpack-plugin": "^5.3.2",
114109
"mini-css-extract-plugin": "^2.2.2",
115-
"node-abi": "^2.30.1",
116110
"node-loader": "^2.0.0",
117111
"npm-run-all": "^4.1.5",
118112
"prettier": "^2.3.2",

src/main/index.js

Lines changed: 22 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,8 @@ function runApp() {
147147
session.defaultSession.cookies.set({
148148
url: url,
149149
name: 'CONSENT',
150-
value: 'YES+'
150+
value: 'YES+',
151+
sameSite: 'no_restriction'
151152
})
152153
})
153154

@@ -769,7 +770,21 @@ function runApp() {
769770
const template = [
770771
{
771772
label: 'File',
772-
submenu: [{ role: 'quit' }]
773+
submenu: [
774+
{
775+
label: 'New Window',
776+
accelerator: 'CmdOrCtrl+N',
777+
click: (_menuItem, _browserWindow, _event) => {
778+
createWindow({
779+
replaceMainWindow: false,
780+
showWindowNow: true
781+
})
782+
},
783+
type: 'normal'
784+
},
785+
{ type: 'separator' },
786+
{ role: 'quit' }
787+
]
773788
},
774789
{
775790
label: 'Edit',
@@ -801,8 +816,12 @@ function runApp() {
801816
{ role: 'toggledevtools' },
802817
{ type: 'separator' },
803818
{ role: 'resetzoom' },
804-
{ role: 'zoomin' },
819+
{ role: 'resetzoom', accelerator: 'CmdOrCtrl+num0', visible: false },
820+
{ role: 'zoomin', accelerator: 'CmdOrCtrl+Plus' },
821+
{ role: 'zoomin', accelerator: 'CmdOrCtrl+=', visible: false },
822+
{ role: 'zoomin', accelerator: 'CmdOrCtrl+numadd', visible: false },
805823
{ role: 'zoomout' },
824+
{ role: 'zoomout', accelerator: 'CmdOrCtrl+numsub', visible: false },
806825
{ type: 'separator' },
807826
{ role: 'togglefullscreen' }
808827
]

src/renderer/App.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
#app {
77
display: flex;
88
flex-wrap: wrap;
9-
font-family: 'Roboto', sans-serif;
9+
font-family: 'Roboto', sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol', 'Noto Color Emoji';
1010
}
1111

1212
.routerView {

src/renderer/App.js

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -334,14 +334,17 @@ export default Vue.extend({
334334
})
335335

336336
$(document).on('auxclick', 'a[href^="http"]', (event) => {
337-
this.handleLinkClick(event)
337+
// auxclick fires for all clicks not performed with the primary button
338+
// only handle the link click if it was the middle button,
339+
// otherwise the context menu breaks
340+
if (event.button === 1) {
341+
this.handleLinkClick(event)
342+
}
338343
})
339344
},
340345

341346
handleLinkClick: function (event) {
342347
const el = event.currentTarget
343-
console.log(this.usingElectron)
344-
console.log(el)
345348
event.preventDefault()
346349

347350
// Check if it's a YouTube link

src/renderer/components/distraction-settings/distraction-settings.js

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,18 @@ export default Vue.extend({
4545
},
4646
hideActiveSubscriptions: function () {
4747
return this.$store.getters.getHideActiveSubscriptions
48+
},
49+
hideVideoDescription: function () {
50+
return this.$store.getters.getHideVideoDescription
51+
},
52+
hideComments: function () {
53+
return this.$store.getters.getHideComments
54+
},
55+
hideLiveStreams: function() {
56+
return this.$store.getters.getHideLiveStreams
57+
},
58+
hideSharingActions: function() {
59+
return this.$store.getters.getHideSharingActions
4860
}
4961
},
5062
methods: {
@@ -68,7 +80,11 @@ export default Vue.extend({
6880
'updateHideLiveChat',
6981
'updateHideActiveSubscriptions',
7082
'updatePlayNextVideo',
71-
'updateDefaultTheatreMode'
83+
'updateDefaultTheatreMode',
84+
'updateHideVideoDescription',
85+
'updateHideComments',
86+
'updateHideLiveStreams',
87+
'updateHideSharingActions'
7288
])
7389
}
7490
})

src/renderer/components/distraction-settings/distraction-settings.vue

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,18 @@
3838
:default-value="hideActiveSubscriptions"
3939
@change="updateHideActiveSubscriptions"
4040
/>
41+
<ft-toggle-switch
42+
:label="$t('Settings.Distraction Free Settings.Hide Video Description')"
43+
:compact="true"
44+
:default-value="hideVideoDescription"
45+
@change="updateHideVideoDescription"
46+
/>
47+
<ft-toggle-switch
48+
:label="$t('Settings.Distraction Free Settings.Hide Sharing Actions')"
49+
:compact="true"
50+
:default-value="hideSharingActions"
51+
@change="updateHideSharingActions"
52+
/>
4153
</div>
4254
<div class="switchColumn">
4355
<ft-toggle-switch
@@ -70,6 +82,18 @@
7082
:default-value="hideLiveChat"
7183
@change="updateHideLiveChat"
7284
/>
85+
<ft-toggle-switch
86+
:label="$t('Settings.Distraction Free Settings.Hide Live Streams')"
87+
:compact="true"
88+
:default-value="hideLiveStreams"
89+
@change="updateHideLiveStreams"
90+
/>
91+
<ft-toggle-switch
92+
:label="$t('Settings.Distraction Free Settings.Hide Comments')"
93+
:compact="true"
94+
:default-value="hideComments"
95+
@change="updateHideComments"
96+
/>
7397
</div>
7498
</div>
7599
<br>

src/renderer/components/download-settings/download-settings.js

Lines changed: 21 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import Vue from 'vue'
22
import FtFlexBox from '../ft-flex-box/ft-flex-box.vue'
33
import FtToggleSwitch from '../ft-toggle-switch/ft-toggle-switch.vue'
4+
import FtSelect from '../ft-select/ft-select.vue'
45
import FtButton from '../ft-button/ft-button.vue'
56
import FtInput from '../ft-input/ft-input.vue'
67
import { mapActions } from 'vuex'
@@ -12,19 +13,36 @@ export default Vue.extend({
1213
components: {
1314
'ft-toggle-switch': FtToggleSwitch,
1415
'ft-flex-box': FtFlexBox,
16+
'ft-select': FtSelect,
1517
'ft-button': FtButton,
1618
'ft-input': FtInput
1719
},
1820
data: function () {
1921
return {
20-
askForDownloadPath: this.$store.getters.getDownloadFolderPath === ''
22+
askForDownloadPath: false,
23+
downloadBehaviorValues: [
24+
'download',
25+
'open'
26+
]
2127
}
2228
},
2329
computed: {
2430
downloadPath: function() {
2531
return this.$store.getters.getDownloadFolderPath
32+
},
33+
downloadBehaviorNames: function () {
34+
return [
35+
this.$t('Settings.Download Settings.Download in app'),
36+
this.$t('Settings.Download Settings.Open in web browser')
37+
]
38+
},
39+
downloadBehavior: function () {
40+
return this.$store.getters.getDownloadBehavior
2641
}
2742
},
43+
mounted: function () {
44+
this.askForDownloadPath = this.downloadPath === ''
45+
},
2846
methods: {
2947
handleDownloadingSettingChange: function (value) {
3048
this.askForDownloadPath = value
@@ -42,7 +60,8 @@ export default Vue.extend({
4260
this.updateDownloadFolderPath(folder.filePaths[0])
4361
},
4462
...mapActions([
45-
'updateDownloadFolderPath'
63+
'updateDownloadFolderPath',
64+
'updateDownloadBehavior'
4665
])
4766
}
4867

src/renderer/components/download-settings/download-settings.vue

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,27 @@
66
</h3>
77
</summary>
88
<hr>
9-
<ft-flex-box class="downloadSettingsFlexBox">
9+
<ft-flex-box>
10+
<ft-select
11+
:placeholder="$t('Settings.Download Settings.Download Behavior')"
12+
:value="downloadBehavior"
13+
:select-names="downloadBehaviorNames"
14+
:select-values="downloadBehaviorValues"
15+
@change="updateDownloadBehavior"
16+
/>
17+
</ft-flex-box>
18+
<ft-flex-box
19+
v-if="downloadBehavior === 'download'"
20+
class="downloadSettingsFlexBox"
21+
>
1022
<ft-toggle-switch
1123
:label="$t('Settings.Download Settings.Ask Download Path')"
1224
:default-value="askForDownloadPath"
1325
@change="handleDownloadingSettingChange"
1426
/>
1527
</ft-flex-box>
1628
<ft-flex-box
17-
v-if="!askForDownloadPath"
29+
v-if="!askForDownloadPath && downloadBehavior === 'download'"
1830
>
1931
<ft-input
2032
class="folderDisplay"
@@ -25,7 +37,7 @@
2537
/>
2638
</ft-flex-box>
2739
<ft-flex-box
28-
v-if="!askForDownloadPath"
40+
v-if="!askForDownloadPath && downloadBehavior === 'download'"
2941
>
3042
<ft-button
3143
:label="$t('Settings.Download Settings.Choose Path')"
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
import Vue from 'vue'
2+
3+
export default Vue.extend({
4+
name: 'FtAgeRestricted',
5+
props: {
6+
contentTypeString: {
7+
type: String,
8+
required: true
9+
}
10+
},
11+
computed: {
12+
emoji: function () {
13+
const emojis = ['😵', '😦', '🙁', '☹️', '😦', '🤫', '😕']
14+
return emojis[Math.floor(Math.random() * emojis.length)]
15+
},
16+
17+
restrictedMessage: function () {
18+
const contentType = this.$t('Age Restricted.Type.' + this.contentTypeString)
19+
return this.$t('Age Restricted.This $contentType is age restricted').replace('$contentType', contentType)
20+
}
21+
}
22+
})

0 commit comments

Comments
 (0)