add isolated tab feature

This commit is contained in:
Fabian Freund
2026-02-27 08:29:50 +01:00
parent 3ef567cc19
commit d24675094d
84 changed files with 3783 additions and 513 deletions
@@ -129,17 +129,27 @@ class _NewTabDefaultSection extends HookConsumerWidget {
Center(
child: SegmentedButton(
showSelectedIcon: false,
segments: const [
ButtonSegment(
segments: [
const ButtonSegment(
value: TabType.regular,
label: Text('Regular'),
icon: Icon(MdiIcons.tab),
),
ButtonSegment(
const ButtonSegment(
value: TabType.private,
label: Text('Private'),
icon: Icon(WebLibreIcons.privateTab),
),
ButtonSegment(
value: TabType.isolated,
label: const Text('Isolated'),
icon: Icon(
MdiIcons.shieldLock,
color: defaultCreateTabType == TabType.isolated
? null
: appColors.isolatedTabTeal,
),
),
],
selected: {defaultCreateTabType},
onSelectionChanged: (value) async {
@@ -156,6 +166,9 @@ class _NewTabDefaultSection extends HookConsumerWidget {
selectedBackgroundColor: appColors.privateSelectionOverlay,
),
TabType.child => null,
TabType.isolated => SegmentedButton.styleFrom(
selectedBackgroundColor: appColors.isolatedSelectionOverlay,
),
},
),
),