3131
3232 <div class =" card bg-base-200 mt-4" >
3333 <div class =" card-body" >
34- <h2 class =" card-title" >Performance</h2 >
34+ <h2 class =" card-title" >Performance & Tab Management </h2 >
3535
3636 <div class =" grid grid-cols-6" >
3737 <div class =" col-span-5" >
3838 <h3 class =" font-bold" >Lightweight Mode</h3 >
39- <p >
40- Reduce memory usage by disabling Tabee on specific domains or URLs. This is useful for
41- sites where you don't need tab modifications.
42- </p >
39+ <p >Reduce memory usage by disabling Tabee on specific domains or URLs.</p >
4340 </div >
4441 <div class =" col-span-1 flex justify-end" >
4542 <input
5148 </div >
5249
5350 <div v-if =" lightweightModeEnabled" class =" mt-4" >
51+ <div class =" grid grid-cols-2 gap-4 mb-4" >
52+ <label class =" label cursor-pointer justify-start gap-2" >
53+ <input
54+ v-model =" lightweightModeApplyToRules"
55+ type =" checkbox"
56+ class =" checkbox checkbox-xs checkbox-primary"
57+ />
58+ <span class =" label-text text-xs" >Apply to Rules</span >
59+ </label >
60+ <label class =" label cursor-pointer justify-start gap-2" >
61+ <input
62+ v-model =" lightweightModeApplyToTabHive"
63+ type =" checkbox"
64+ class =" checkbox checkbox-xs checkbox-primary"
65+ />
66+ <span class =" label-text text-xs" >Apply to Tab Hive</span >
67+ </label >
68+ </div >
69+
5470 <div class =" mb-4" >
5571 <button class =" btn btn-xs btn-outline btn-primary" @click =" showAddPatternModal" >
5672 Add Pattern
153169 </div >
154170 </div >
155171 </dialog >
156- </div >
157- </div >
158172
159- <div class =" card bg-base-200 mt-4" >
160- <div class =" card-body" >
161- <h2 class =" card-title" >🍯 Tab Hive</h2 >
173+ <div class =" divider my-6" ></div >
162174
163175 <div class =" grid grid-cols-6" >
164176 <div class =" col-span-5" >
165- <h3 class =" font-bold" >Auto-Close Inactive Tabs</h3 >
177+ <h3 class =" font-bold" >🍯 Tab Hive: Auto-Close Inactive Tabs</h3 >
166178 <p >
167179 Automatically close tabs that have been inactive for a specified duration. Closed tabs
168- will be saved in the side panel for easy restoration.
180+ will be saved in Tab Hive for easy restoration.
169181 </p >
170182 </div >
171183 <div class =" col-span-1 flex justify-end" >
@@ -308,6 +320,12 @@ const lightweightModeEnabled = ref(rulesStore.settings.lightweight_mode_enabled
308320const lightweightModePatterns = ref <LightweightModePattern []>(
309321 rulesStore .settings .lightweight_mode_patterns ?? []
310322);
323+ const lightweightModeApplyToRules = ref (
324+ rulesStore .settings .lightweight_mode_apply_to_rules ?? true
325+ );
326+ const lightweightModeApplyToTabHive = ref (
327+ rulesStore .settings .lightweight_mode_apply_to_tab_hive ?? true
328+ );
311329const addPatternModal = ref <HTMLDialogElement | null >(null );
312330const newPattern = ref ({
313331 type: ' domain' as ' domain' | ' regex' ,
@@ -334,6 +352,16 @@ watch(lightweightModeEnabled, async (enabled) => {
334352 });
335353});
336354
355+ watch (lightweightModeApplyToRules , async (enabled ) => {
356+ rulesStore .settings .lightweight_mode_apply_to_rules = enabled ;
357+ await rulesStore .save ();
358+ });
359+
360+ watch (lightweightModeApplyToTabHive , async (enabled ) => {
361+ rulesStore .settings .lightweight_mode_apply_to_tab_hive = enabled ;
362+ await rulesStore .save ();
363+ });
364+
337365watch (autoCloseEnabled , async (enabled ) => {
338366 rulesStore .settings .auto_close_enabled = enabled ;
339367 await rulesStore .save ();
0 commit comments