Commit Graph

23 Commits

Author SHA1 Message Date
Jason 32a08d1741
Set a max length for many inputs (#5156)
* Set a max length of 100 for most inputs

Excluded are playlist descriptions, which presumably deserve to have some leeway, and the password input, to prevent the edge case of a user being locked out if they had a longer one set (and also why not for this one).

* Remove maxlength where it constrains valid inputs

* Update proxy port and playlist description maxlength

* Implement suggested changes

* Update with suggested changes to make null maxlength the default

* Implement suggested changes
2024-05-29 23:34:11 +00:00
Jason 7410beacf0
Intuitive input bindings (#4970)
* Configure 'Enter' to submit form being edited

* Configure Ctrl+F keyboard listeners on pages with prominent search bar

* Move lambda data functions to methods

* Remove unnecessary 'return's

* Add Ctrl+F handling to Channel search bar

* Fix disabled ft-select label bug

* Fix linting issue
2024-04-29 18:39:17 +02:00
Jason d52ab88e7f
Add icons to dropdowns (#5006)
* Implement icons for all ft-selects

* Remove unnecessary v-if

* Update to use getIconForSortPreference util function with all arrows pointing down

* Update src/renderer/views/Playlist/Playlist.js

Co-authored-by: PikachuEXE <git@pikachuexe.net>

---------

Co-authored-by: PikachuEXE <git@pikachuexe.net>
2024-04-25 22:29:52 +02:00
absidue bb7d90be05
Fix imports of the "electron" module that are missing an Electron guard (#4935) 2024-04-14 13:16:55 +00:00
ChunkyProgrammer d8387b76d7
Add i18n-eslint-plugin (#4763)
* add i18n-eslint-plugin

* remove `FreeTube` `Invidious` and `YouTube` from locale files as those shouldn't be translated

* Remove testing code

* Uncomment code

* use separate getColorTranslations function

* make suggested changes

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

* Add back blank line between import & export

---------

Co-authored-by: absidue <48293849+absidue@users.noreply.github.com>
Co-authored-by: PikachuEXE <git@pikachuexe.net>
2024-04-07 14:58:15 +00:00
pkrasicki ead8fc23a9
Fix style for the Select component (#4405)
* Fix style for the Select component

Fixes #1804

Fixes the width of dropdowns and changes their style a little bit

* Fix lint

* Fix comments partially obscuring the sort dropdown

* Move select tooltip
2024-01-03 09:11:10 +08:00
ChunkyProgrammer 7304d75239
Localize proxy test info when possible (#4255)
* Localize proxy test info when possible

* Use a second find in-case a locale with the same language is added in the future

Co-authored-by: Jason <84899178+jasonhenriquez@users.noreply.github.com>

* Fix syntax error

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

---------

Co-authored-by: Jason <84899178+jasonhenriquez@users.noreply.github.com>
Co-authored-by: PikachuEXE <pikachuexe@gmail.com>
2023-10-31 18:07:42 +01:00
absidue 046462e024
Fix proxy settings test (#4192) 2023-10-20 15:40:40 +00:00
absidue 723739f724
Cleanup some template conditionals (#3888) 2023-08-16 08:50:32 +00:00
absidue 45d679b84b
Clean up unused component properties (#3458) 2023-04-25 20:03:36 -04:00
absidue 2cd8f0f2d3
Switch from Vue.extend to defineComponent (#3066) 2023-01-18 08:50:02 +01:00
absidue 75bf0377ca
Hide the proxy settings in the web build (#3037) 2023-01-08 08:29:06 +08:00
absidue 8f55a648b1
Cleanup unused component imports (#2773) 2022-10-27 09:34:39 +00:00
absidue 3aa080d707
Make showToast a helper (#2695) 2022-10-14 05:59:49 +00:00
absidue 63946f7561
Add a settings section component to reduce duplicate code (#2609) 2022-09-24 09:12:11 +00:00
absidue 061a7c8db1
Replace jquery getJSON and get with native fetch (#2591)
* Replace jquery getJSON and get with native fetch

* Remove unnecessary console.log
2022-09-21 07:05:03 +00:00
Preston ad01e95ec4
Change URL for proxy test (#2434) 2022-07-31 20:26:04 -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
Jason 41fedf8b2e
Disabling mutually exclusive settings (#1822)
* Adds :disabled styling/functionality for ft-button & ft-select

* Disable proxy, external player, & SponsorBlock settings when applicable

* Changes Invidious General Settings, Proxy Settings, and SponsorBlock settings to disappear when appropriate

* Update ft-toggle-switch.sass

* Switches to styling with disabled class for ft-toggle-switch

* Sets cursor to not-allowed for disabled controls
2021-10-20 13:14:49 +00:00
PikachuEXE 87e1093c4d
Update top nav input box action button icon depends on input (#1738)
* Rename `showArrow` to `showActionButton`

* * Display different icon for action button when input text look like a Youtube URL

* ! Fix transition for button appearing absent

* * Update to use new icon for all FT supported URLs

* Update src/renderer/components/ft-input/ft-input.js

Co-authored-by: Jason <84899178+jasonhenriquez@users.noreply.github.com>

* * Update action button to look disabled when input text is empty

* * Disable button hover/active visual effect when "disabled"

* * Make action button only respond to cursor when enabled

Co-authored-by: Jason <84899178+jasonhenriquez@users.noreply.github.com>
2021-10-01 07:38:33 +00:00
Jason cfeac8c7f1
Collapsible Settings Sections (#1699)
* Adds base dropdown ability to settings page with <details> & <summary>

* Adjusts styling of settings page

Replaces css stylesheets with sass stylesheets on some settings elements for better standardization of styling. Removes now unnecessary ft-card, .card, etc styling. Adds styling to new dropdown functionality.

* Update subscription-settings.sass

* Update Settings.css
2021-09-15 10:03:00 +08:00
Svallinn af0353ea32
Refactor: Erase `@electron/remote` references and other dangerous calls
The `remote` module is deprecated and `@electron/remote` is unnecessary,
since the `ipcMain` and `ipcRenderer` can replace their functionality,
providing better performance and better security.

All other dangerous calls (mainly pulling main process constructs into
the renderer process) have also been removed.
2021-05-22 00:49:48 +01:00
Preston 6d7d874bc0 Add Proxy configuration to settings. Fix ft-video-list height when using list display 2021-01-14 13:51:33 -05:00