diff options
Diffstat (limited to 'apps/web/src/stores/text-properties-store.ts')
| -rw-r--r-- | apps/web/src/stores/text-properties-store.ts | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/apps/web/src/stores/text-properties-store.ts b/apps/web/src/stores/text-properties-store.ts index b3ce3689..c7476b46 100644 --- a/apps/web/src/stores/text-properties-store.ts +++ b/apps/web/src/stores/text-properties-store.ts @@ -1,33 +1,33 @@ import { create } from "zustand";
import { persist } from "zustand/middleware";
-export type TextPropertiesTab = "transform" | "style";
+export type TextPropertiesTab = "text" | "transform";
export interface TextPropertiesTabMeta {
- value: TextPropertiesTab;
- label: string;
+ value: TextPropertiesTab;
+ label: string;
}
export const TEXT_PROPERTIES_TABS: ReadonlyArray<TextPropertiesTabMeta> = [
- { value: "transform", label: "Transform" },
- { value: "style", label: "Style" },
+ { value: "text", label: "Text" },
+ { value: "transform", label: "Transform" },
] as const;
export function isTextPropertiesTab(value: string): value is TextPropertiesTab {
- return TEXT_PROPERTIES_TABS.some((t) => t.value === value);
+ return TEXT_PROPERTIES_TABS.some((t) => t.value === value);
}
interface TextPropertiesState {
- activeTab: TextPropertiesTab;
- setActiveTab: (tab: TextPropertiesTab) => void;
+ activeTab: TextPropertiesTab;
+ setActiveTab: (tab: TextPropertiesTab) => void;
}
export const useTextPropertiesStore = create<TextPropertiesState>()(
- persist(
- (set) => ({
- activeTab: "transform",
- setActiveTab: (tab) => set({ activeTab: tab }),
- }),
- { name: "text-properties" }
- )
+ persist(
+ (set) => ({
+ activeTab: "text",
+ setActiveTab: (tab) => set({ activeTab: tab }),
+ }),
+ { name: "text-properties" },
+ ),
);
|
