Skip to content

Migrate the Settings component to the composition API#8708

Merged
FreeTubeBot merged 2 commits intoFreeTubeApp:developmentfrom
absidue:settings-composition-api-migration
Mar 5, 2026
Merged

Migrate the Settings component to the composition API#8708
FreeTubeBot merged 2 commits intoFreeTubeApp:developmentfrom
absidue:settings-composition-api-migration

Conversation

@absidue
Copy link
Member

@absidue absidue commented Feb 22, 2026

Pull Request Type

  • Composition API migration

Description

This pull request migrates the Settings component to the composition API. Currently the Settings component does a lot of direct DOM manipulations in the FtSettingsMenu component (querySelector, getElementById, adding and removing classes and focusing), so I replaced that in a second commit to use template refs and props, to decouple the two components a bit and make future maintenance easier. Another change is that the icons are now passed in fully from the Settings component into the FtSettingsMenu component, instead of just the name strings being passed through and the full array assembled in the FtSettingsMenu component as that will make a future change that I am planning to do of directly importing the icons where they are used and referencing the import/variable in the component and template directly (currently we register them locally and then have FontAwesome look them up by name at runtime).

Testing

Open the settings, check that the layout and the back button work in both desktop and mobile view. Additionally check that changing the settings sort setting works correctly.

Desktop

  • OS: Windows
  • OS Version: 11

@FreeTubeBot FreeTubeBot enabled auto-merge (squash) February 22, 2026 14:59
@github-actions github-actions bot added the PR: waiting for review For PRs that are complete, tested, and ready for review label Feb 22, 2026
Copy link
Member

@PikachuEXE PikachuEXE left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

check that the layout and the back button work in both desktop and mobile view

This reads like there is a back button on desktop... which there isn't one I think?

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

check that the layout and the back button work in both desktop and mobile view

This reads like there is a back button on desktop... which there isn't one I think?

@PikachuEXE i think this still counts as desktop?

VirtualBoxVM_LkWHomcbSn.mp4

Idk if this weird stuff is even related to this PR?

Dropdown opens on a weird place

VirtualBoxVM_ACKIYNAU3S.mp4

Text is black?

VirtualBoxVM_IDAQmBWvLb.mp4

@PikachuEXE
Copy link
Member

@efb4f5ff-1298-471a-8973-3d47447115dc
I guess for "desktop" I assume wide screens, I guess not, then "desktop" mean nothing here (coz it's present with screen width < X)

@absidue
Copy link
Member Author

absidue commented Feb 28, 2026

He., sorry for the confusion, in hindsight my sentence in the testing section was badly phrased. I had intended to ask you to test both desktop and mobile views and specifically the navigation behaviour e.g. side bar updates while scrolling on desktop, opening the settings in the mobile view shows the menu first, clicking on a link shows that section, clicking back takes you back to the menu, etc, as those are things that would be affected by the changes in the second commit.

@absidue
Copy link
Member Author

absidue commented Feb 28, 2026

Idk if this weird stuff is even related to this PR?

Can you reproduce it on the development branch?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Idk if this weird stuff is even related to this PR?

Can you reproduce it on the development branch?

Yes, so this PR is good to go

@FreeTubeBot FreeTubeBot merged commit 099ac02 into FreeTubeApp:development Mar 5, 2026
6 checks passed
@github-actions github-actions bot removed the PR: waiting for review For PRs that are complete, tested, and ready for review label Mar 5, 2026
@absidue absidue deleted the settings-composition-api-migration branch March 5, 2026 14:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants