Commit Graph

42 Commits

Author SHA1 Message Date
absidue c0f98eeafe
Use named parameters instead of $ and % in localised strings (#2685)
* Use named parameters instead of $ and % in localised strings

* Fix URL warning again

* Update placeholders in most locales

* Let the translators fix the problematic RTL strings

* Fix the missing quotes in some of the YAML files
2022-10-13 11:51:15 +00:00
ChunkyProgrammer 7822f7423e
Remove console.logs (#2606)
* remove console.logs

* use 'off' instead of 0
2022-09-23 09:04:10 +08:00
Emma 25d954f990
Cleaning up calls to the Clipboard API (#2597)
* Added a copyToClipboard function to utils

This should make it easier to handle errors which
result from the clipboard API (which are more likely
in web builds). This should also make it easier to handle
copying to clipboard in cordova builds by abstracting the
platform specific code out of the views and moving it
all into one function.

* Moved the $t function out of utils

* Removing locale snippets I was using and am not now

* Added function comment to copyToClipboard

* Adding some missing references

* Adding an additional check

* Re-reviewing my changes, I found a mistake

* Update src/renderer/store/modules/utils.js

Co-authored-by: absidue <48293849+absidue@users.noreply.github.com>

* Update static/locales/en-US.yaml

Co-authored-by: ChunkyProgrammer <78101139+ChunkyProgrammer@users.noreply.github.com>

* Reverting the language back to what it was previously

* Switching to using i18n.t()

instead of handling the translations myself.
Also, it looks like eslint removed a tab.

Co-authored-by: absidue <48293849+absidue@users.noreply.github.com>
Co-authored-by: ChunkyProgrammer <78101139+ChunkyProgrammer@users.noreply.github.com>
2022-09-21 15:00:21 +08:00
ChunkyProgrammer 8fa182e246
Properly localize numbers (#2557)
* localize numbers properly

* Remove tostring

Co-authored-by: Aiz <66974576+Aiz0@users.noreply.github.com>

Co-authored-by: Aiz <66974576+Aiz0@users.noreply.github.com>
2022-09-19 20:14:53 +08:00
absidue f2d2827e0f
Fix some web issues and cleanup (#2582) 2022-09-17 08:19:31 +00:00
absidue 62829b736a
Electron variable at build time instead of at runtime (#2574) 2022-09-15 08:59:09 +00:00
ChunkyProgrammer 84b4d230ab
fix unsubscribe from "All Channels" profile (#2451) 2022-08-16 11:45:39 +02:00
MarmadileManteater 33cf88ce31
Mapping the invidious API field to the view (#2483)
Added a line to map the field "authorId" to "channelId"
on the featured channels that come from the Invidious API
because the Channel view expects related channels to have
the property "channelId". This is related to FreeTubeApp#2481.
2022-08-15 23:14:59 +00:00
absidue 6334df0ad0
Fix channel page ID handling (#2457)
* Fix channel page ID check race condition

* Correctly handle the different channel ID types
2022-08-08 09:26:04 +00:00
ChunkyProgrammer 3321fa91e4
Add Parental Controls (#1456)
* start to implement some parental controls

* Hide share + Hide Unsubscribe

* Hide live streams

* fix hide live streams

* Add "parental-control-settings"

* Implement Hide Live Streams & Hide "Age Restricted"

* Hide live streams from Subscriptions + fix hide live streams from search

* enable safe search on showFamilyFriendlyOnly

* Move some settings from parental control to distraction free

* fix channel loading

* make parental control settings collapsible

* fix lint

* dont show age restricted on videos that are loading

* improve hide live videos

* code refactor

* grammar

* nvm im dumb

* use named placeholder for age restricted message

* improve readability

* change Hide Description to Hide Video Description

* update translated strings

* fix age restricted component

Co-authored-by: Preston <freetubeapp@protonmail.com>
Co-authored-by: peepopoggers <72892531+peepopoggers@users.noreply.github.com>
2022-06-21 08:14:15 +02:00
ChunkyProgrammer da095adc8c
Allow Unsubscribing from Deleted Channels (#2283)
* unsub from deleted

* reset error message on invidious channel load

* fix error channels not showing

* Use errorMessage instead of isErrorMessage

Co-authored-by: absidue <48293849+absidue@users.noreply.github.com>

* Change "Error Channels" to "Channels with Errors"

Co-authored-by: absidue <48293849+absidue@users.noreply.github.com>

* use find instead of find index

Co-Authored-By: absidue <48293849+absidue@users.noreply.github.com>
Co-Authored-By: PikachuEXE <pikachuexe@gmail.com>

Co-authored-by: absidue <48293849+absidue@users.noreply.github.com>
Co-authored-by: PikachuEXE <pikachuexe@gmail.com>
2022-06-03 14:04:50 +00:00
ChunkyProgrammer 74dc309803
Fix: Update thumbnail url and channel name for subscriptions when change detected (#1783)
* Update thumbnails of subscriptions

* refactor

* update channel names

* movie update thumbnail action to profiles.js

* fix updating with invidious

* apply code changes

* simplify update condition logic

* remove unneeded variables

* inline variables, use for of

* fix channel null check
2022-06-03 12:52:35 +00:00
bob1520 a9dc9c028d
Fix: wrong info displayed when quickly navigate from a channel to another (#2259)
* Fix: wrong info displayed when you quickly navigate from a channel to another (Invidious)

* localapi

* id
2022-05-25 11:32:19 +02:00
bob1520 8b50045e78
channel fix (banner, playlist) (#2215)
* channel fix (banner, playlist)

* remove console.log(response)
2022-05-12 09:37:25 +00:00
ChunkyProgrammer 927225d1f4
update yt-channel-info (#2126)
* update yt-channel-info

* update to 3.0.1

* Update yarn.lock
2022-04-05 23:05:15 -04:00
Svallinn daecf944fb
Store Revamp / Full database synchronization across windows (#1833)
* History: Refactor history module

* Profiles: Refactor profiles module

* IPC: Move channel ids to their own file and make them constants

* IPC: Replace single sync channel for one channel per sync type

* Everywhere: Replace default profile id magic strings with constant ref

* Profiles: Refactor `activeProfile` property from store

This commit makes it so that `activeProfile`'s getter returns
the entire profile, while the related update function only needs
the profile id (instead of the previously used array index)
to change the currently active profile.

This change was made due to inconsistency regarding the active profile
when creating new profiles.
If a new profile coincidentally landed in the current active profile's
array index after sorting, the app would mistakenly change to it
without any action from the user apart from the profile's creation.
Turning the profile id into the selector instead solves this issue.

* Revert "Store: Implement history synchronization between windows"

This reverts commit 99b61e6178.

This is necessary for an upcoming improved implementation of the
history synchronization.

* History: Remove unused mutation

* Everywhere: Create abstract database handlers

The project now utilizes abstract handlers to fetch, modify
or otherwise manipulate data from the database.

This facilitates 3 aspects of the app, in addition of
making them future proof:

- Switching database libraries is now trivial
Since most of the app utilizes the abstract handlers, it's incredibly
easily to change to a different DB library.
Hypothetically, all that would need to be done is to simply replace the
the file containing the base handlers, while the rest of the app
would go unchanged.

- Syncing logic between Electron and web is now properly separated
There are now two distinct DB handling APIs: the Electron one and
the web one.
The app doesn't need to manually choose the API, because it's detected
which platform is being utilized on import.

- All Electron windows now share the same database instance
This provides a single source of truth, improving consistency
regarding data manipulation and windows synchronization.

As a sidenote, syncing implementation has been left as is
(web unimplemented; Electron only syncs settings, remaining
datastore syncing will be implemented in the upcoming commits).

* Electron/History: Implement history synchronization

* Profiles: Implement suplementary profile creation logic

* ft-profile-edit: Small fix on profile name missing display

* Electron/Profiles: Implement profile synchronization

* Electron/Playlists: Implement playlist synchronization
2021-12-15 13:42:24 -05:00
ChunkyProgrammer 9bf4742cf9
Recognize more channel links (#1455)
* Update channelPattern regex

* redirect to relevant sub page

* Simplify regex

Co-authored-by: PikachuEXE <pikachuexe@gmail.com>

* fix regression

- fix regression from commit 76f0d7512a
- add comment to explain regex

Co-authored-by: Preston <freetubeapp@protonmail.com>
Co-authored-by: PikachuEXE <pikachuexe@gmail.com>
2021-11-02 11:45:50 +00:00
ChunkyProgrammer 11bb81795d
fix featured icons not loading (#1552)
Co-authored-by: Preston <freetubeapp@protonmail.com>
2021-08-20 18:45:00 +00:00
ChunkyProgrammer 93a48ffe24
Translate window titles (#1321)
* Update Titles to change based on locale

* Update Title on Forward/Backwards navigation

* Revert "Update Title on Forward/Backwards navigation"

This reverts commit 0a57825e92.

* Translate Window Titles

-Updated en-US & en_GB localization files to include 'Playlist" and "Profile Settings"
- Updated app to dynamically change titles + translate (App.js sets title instead of router now)
- Channel & Video get title based on Channel Name & Video name (changing those titles are in their respective views)

* Revert "Update Titles to change based on locale"

This reverts commit 9e80816067.

* Re-add update title to channel view

* fix playlist title

* Fix 'Edit Profile' title
2021-07-21 11:45:02 -04:00
Svallinn 40d7278383
Invidious: Randomize instance on startup
There are now two separate settings related to Invidious instances:
- currentInvidiousInstance
- defaultInvidiousInstance

'currentInvidiousInstance' is a value that exists solely in memory
and it's the value used by the app to make the API calls,
while 'defaultInvidiousInstance' is the value that can be persisted
in the database by user action and will be used to initiate
the 'currentInvidiousInstance' on startup.

If the user has not saved a default value to the database,
'currentInvidiousInstance' is randomized from
a fetched list of viable candidates.
2021-07-03 02:55:56 +01:00
Svallinn 6ccc7e9fa4
Refactor: Swap `dispatch`/`commit` calls with mapped actions/mutations 2021-05-22 00:56:32 +01:00
Preston 689479eb21 Channel Fixes and finish quality change logic 2021-04-30 17:18:45 -04:00
Preston d4370f25f9 Update Channel module in Local API 2021-03-04 16:51:56 -05:00
Preston ef5aee3576 Update local API comment module and fix Invidious logic on channel page 2021-02-15 09:59:35 -05:00
Preston eab93c2b61 Fix network leak to Invidious instance when viewing channel playlists on Local API 2021-01-11 11:26:14 -05:00
Preston acf9b850c2 Proxy channel profile icons and banners through Invidious when API is preferred 2020-10-13 11:06:04 -04:00
Preston 854fd08f9c Hide subscriber count in channel view if 0 is returned 2020-10-06 17:45:30 -04:00
tayloraviets d5970f58c6
PR ready distraction free feature (#596)
* PR ready distraction free feature

Signed-off-by: Taylor <tayloraviets@gmail.com>

* presumably fixed linter issues

Signed-off-by: Taylor <tayloraviets@gmail.com>

* addressed PR issues and hopefully made the linter happy

Signed-off-by: Taylor <tayloraviets@gmail.com>

* fixed more linter issues

Signed-off-by: Taylor <tayloraviets@gmail.com>

* fixed more linter issues again

Signed-off-by: Taylor <tayloraviets@gmail.com>

* fixed more linter issues again.

Signed-off-by: Taylor <tayloraviets@gmail.com>

* moved bad quote

Signed-off-by: Taylor <tayloraviets@gmail.com>
2020-10-05 22:27:32 -04:00
Preston 66ab2b11b9 Clear out more data in channel view to prevent other channel data from showing up 2020-09-20 22:20:40 -04:00
Preston 35b35b2525 Fix Locale and messaging issues 2020-09-16 08:51:24 -04:00
Preston 2a0c062915 Add subscription manager within profile settings. Add Upcoming video information. Other changes 2020-09-15 22:07:54 -04:00
Preston 9b7b240de4 Add proper logic for route change 2020-09-02 21:06:49 -04:00
Preston 1e035105d1 Finish Profile Logic and working subscriptions 2020-09-01 23:21:32 -04:00
Luca 4e822d8093 Turn the subscriber number into an integer number. Sometimes an issue with a somewhat low decimal 1 caused the number to have 9 decimal places 2020-08-19 23:21:39 +02:00
Preston 306335ab16 Have channel toast messages show up again 2020-08-13 14:21:25 -04:00
Preston 99524f3556 Add Locale Strings to Channel and Search pages 2020-08-08 23:15:00 -04:00
Preston 94b6ababf3 Add API Fallback to Channel view, update dependencies and add Windows Portable build 2020-07-29 22:58:07 -04:00
Preston a460fd08ce Fix channel banners and temporarily remove RPM for testing 2020-07-16 23:14:26 -04:00
Preston b625683a2e Add error handling for local channel API and add check for missing channel info 2020-07-11 18:36:42 -04:00
Preston 56fd7fbaa5 Fix banner URL in Channel View 2020-06-23 23:15:14 -04:00
Preston 71fbb6dde6 Add local API for Channel Info 2020-06-23 22:40:34 -04:00
Preston ded6534d16 Push Latest Code to Repository 2020-02-16 13:30:00 -05:00