Skip to content

Fix trailing slash removed while typing#9316

Open
PikachuEXE wants to merge 4 commits into
FreeTubeApp:developmentfrom
PikachuEXE:fix/auto-trailing-slash-removal
Open

Fix trailing slash removed while typing#9316
PikachuEXE wants to merge 4 commits into
FreeTubeApp:developmentfrom
PikachuEXE:fix/auto-trailing-slash-removal

Conversation

@PikachuEXE

@PikachuEXE PikachuEXE commented Jun 23, 2026

Copy link
Copy Markdown
Member

Pull Request Type

  • Bugfix
  • Feature Implementation
  • Documentation
  • Other

Related issue

Better version of #3776
If this works can do the same for #8228
Closes #8228

Description

FT was updating value on typing (even with debounce)
So this PR updates on blur (should be typing/pasting ended) instead of input event

Screenshots

Test yourself to be accurate~

Testing

#3303 (comment)

Desktop

  • OS:
  • OS Version:
  • FreeTube version:

Additional context

Draft coz dunno how to make it also update input value on blur (even it's already committed
Edit 1: Used setText but dunno if that's proper
Edit 2: It seems setText is needed due to if sanitized value is set already (no slash) and slash value is input, the stored value is NOT updated and thus won't make input component to refresh its displayed input data
If a new value is input then the input data is updated

@PikachuEXE PikachuEXE marked this pull request as ready for review June 23, 2026 00:31
@github-actions github-actions Bot added the PR: waiting for review For PRs that are complete, tested, and ready for review label Jun 23, 2026
@FreeTubeBot FreeTubeBot enabled auto-merge (squash) June 23, 2026 00:32
@PikachuEXE PikachuEXE force-pushed the fix/auto-trailing-slash-removal branch from 1bcb7a3 to 39854c7 Compare June 23, 2026 00:39
@PikachuEXE PikachuEXE force-pushed the fix/auto-trailing-slash-removal branch from 94056b4 to 9afbb6e Compare June 23, 2026 00:54
@Shadorc

Shadorc commented Jun 23, 2026

Copy link
Copy Markdown
Contributor

In the Invidious API URL, if I type https:// and click elsewhere, it does nothing has expected, but if I add another / and click elsewhere it leads to https:, is it expected?

@PikachuEXE

Copy link
Copy Markdown
Member Author

I have no idea what to do with those invalid values
The old logic does allow https:// for some reason but that could be due to handling typing issue
I am just fixing the slash removed during typing issue not the invalid value handling issue

@Shadorc

Shadorc commented Jun 23, 2026

Copy link
Copy Markdown
Contributor

Indeed, invalid values handling is probably more #3161 (comment) than #8228
It's cool that the commit is now done on blur, it prevents requesting invalid URLs while the user is typing!

@efb4f5ff-1298-471a-8973-3d47447115dc

Copy link
Copy Markdown
Member

In the Invidious API URL, if I type https:// and click elsewhere, it does nothing has expected, but if I add another / and click elsewhere it leads to https:, is it expected?

Oh rip i read this one after i hit approve. Is this an issue that needs to be addressed here?

@Shadorc

Shadorc commented Jun 26, 2026

Copy link
Copy Markdown
Contributor

In the comments that followed, we figured it should probably be addressed by this issue #3161 (comment).

@github-actions github-actions Bot added PR: merge conflicts / rebase needed and removed PR: waiting for review For PRs that are complete, tested, and ready for review labels Jun 28, 2026
@github-actions

Copy link
Copy Markdown
Contributor

This pull request has conflicts, please resolve those before we can evaluate the pull request.

* development:
  Fix: Hide 'Minimize to system tray' setting on Wayland (FreeTubeApp#9208)
  Translated using Weblate (Hungarian)
  Fix: import history from youtube adding trailing space to title (FreeTubeApp#9204)
  Fix keyboard shortcuts arent't working during "SABR backoff" (FreeTubeApp#9315)
  Fix incomplete watch progresss bar if video length has milliseconds (FreeTubeApp#9267)
  Translated using Weblate (Hungarian)
  Fix default quality not working when video aspect ratio is not 16/9 or 9/16 (FreeTubeApp#9312)
  Remove error when 'publishedText' is missing as it is a valid state (FreeTubeApp#9321)
  Fix LibRedirect download link in README (FreeTubeApp#9323)
  Bump actions/cache/restore from 5.0.5 to 6.0.0 (FreeTubeApp#9329)
  Bump actions/cache/save from 5.0.5 to 6.0.0 (FreeTubeApp#9330)
  Translated using Weblate (French)
  Fix premierDate parsing in subscription (FreeTubeApp#9309)

# Conflicts:
#	src/renderer/components/GeneralSettings/GeneralSettings.vue
@github-actions

github-actions Bot commented Jul 6, 2026

Copy link
Copy Markdown
Contributor

This pull request has conflicts, please resolve those before we can evaluate the pull request.

@github-actions github-actions Bot added PR: merge conflicts / rebase needed and removed PR: waiting for review For PRs that are complete, tested, and ready for review labels Jul 6, 2026
* development: (24 commits)
  Add dependabot groups for actions/cache and github/codeql-action (FreeTubeApp#9373)
  Handle compact published dates e.g. 1w ago in LockupViews (FreeTubeApp#9374)
  Migrate to the vue-i18n composition API (FreeTubeApp#9375)
  Bump electron from 42.4.1 to 42.5.2 (FreeTubeApp#9362)
  Bump eslint-plugin-unicorn from 69.0.0 to 70.0.0 in the eslint group (FreeTubeApp#9367)
  Bump actions/cache/restore from 6.0.0 to 6.1.0 (FreeTubeApp#9366)
  Bump actions/cache/save from 6.0.0 to 6.1.0 (FreeTubeApp#9365)
  Bump js-yaml from 5.2.0 to 5.2.1 (FreeTubeApp#9369)
  Fix lazy rendering on channel home pages (FreeTubeApp#9336)
  Fix publish time parsing (FreeTubeApp#9310)
  Fix online playlist parsing & revert workaround with youtubei.js update (FreeTubeApp#9325)
  Fix parsing view counts in shorts-only playlists (FreeTubeApp#9333)
  Build static runtime AppImages with electron-builder (FreeTubeApp#9339)
  use new matrix icon (FreeTubeApp#9359)
  Translated using Weblate (Polish)
  Bump the webpack group across 1 directory with 2 updates (FreeTubeApp#9347)
  Bump the stylelint group across 1 directory with 3 updates (FreeTubeApp#9345)
  Bump vue from 3.5.38 to 3.5.39 (FreeTubeApp#9353)
  Bump js-yaml from 4.2.0 to 5.2.0 (FreeTubeApp#9348)
  Bump globals from 17.6.0 to 17.7.0 (FreeTubeApp#9350)
  ...

# Conflicts:
#	src/renderer/components/GeneralSettings/GeneralSettings.vue
@PikachuEXE PikachuEXE added the PR: waiting for review For PRs that are complete, tested, and ready for review label Jul 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

PR: waiting for review For PRs that are complete, tested, and ready for review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: Input fields within the SponsorBlock settings removes character while typing

3 participants