From f8e69f9cc25bb9d0a7336337d5f81d36d568a8ab Mon Sep 17 00:00:00 2001 From: Anton Gunnarsson Date: Fri, 23 Jan 2026 12:33:14 +0000 Subject: [PATCH] Merged in chore/remove-unused-files (pull request #3483) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit chore: Remove unused files * Remove unused files Approved-by: Matilda Landström --- .../TempDesignSystem/Form/Select/index.tsx | 40 ------------------- .../TempDesignSystem/Form/Select/select.ts | 29 -------------- apps/scandic-web/types/components/image.ts | 21 ---------- .../types/components/myPages/stays/button.ts | 4 -- .../lib/components/Form/utils/index.ts | 1 - .../lib/components/Loading/index.tsx | 1 - .../lib/components/Progress/variants.ts | 10 ----- packages/design-system/lib/tokens.ts | 1 - 8 files changed, 107 deletions(-) delete mode 100644 apps/scandic-web/components/TempDesignSystem/Form/Select/index.tsx delete mode 100644 apps/scandic-web/components/TempDesignSystem/Form/Select/select.ts delete mode 100644 apps/scandic-web/types/components/image.ts delete mode 100644 apps/scandic-web/types/components/myPages/stays/button.ts delete mode 100644 packages/design-system/lib/components/Form/utils/index.ts delete mode 100644 packages/design-system/lib/components/Loading/index.tsx delete mode 100644 packages/design-system/lib/components/Progress/variants.ts delete mode 100644 packages/design-system/lib/tokens.ts diff --git a/apps/scandic-web/components/TempDesignSystem/Form/Select/index.tsx b/apps/scandic-web/components/TempDesignSystem/Form/Select/index.tsx deleted file mode 100644 index e4e44c4af..000000000 --- a/apps/scandic-web/components/TempDesignSystem/Form/Select/index.tsx +++ /dev/null @@ -1,40 +0,0 @@ -"use client" -import { useController, useFormContext } from "react-hook-form" - -import DeprecatedSelect from "@scandic-hotels/design-system/DeprecatedSelect" - -import type { SelectProps } from "./select" - -export default function Select({ - className, - items, - label, - disabled, - name, - isNestedInModal = false, - registerOptions = {}, -}: SelectProps) { - const { control } = useFormContext() - const { field } = useController({ - control, - name, - rules: registerOptions, - }) - - return ( - - ) -} diff --git a/apps/scandic-web/components/TempDesignSystem/Form/Select/select.ts b/apps/scandic-web/components/TempDesignSystem/Form/Select/select.ts deleted file mode 100644 index ab68d70a0..000000000 --- a/apps/scandic-web/components/TempDesignSystem/Form/Select/select.ts +++ /dev/null @@ -1,29 +0,0 @@ -import type { ReactElement } from "react" -import type { Key } from "react-aria-components" -import type { RegisterOptions } from "react-hook-form" - -interface ReactAriaSelectProps - extends Omit< - React.SelectHTMLAttributes, - "onSelect" | "value" - > { - defaultSelectedKey?: Key - items: { label: string; value: Key }[] - label: string - name: string - maxHeight?: number - showRadioButton?: boolean - discreet?: boolean - isNestedInModal?: boolean - // eslint-disable-next-line @typescript-eslint/no-explicit-any - optionsIcon?: ReactElement -} - -export interface SelectProps - extends Omit< - React.SelectHTMLAttributes, - "name" | "onSelect" | "placeholder" - >, - Omit { - registerOptions?: RegisterOptions -} diff --git a/apps/scandic-web/types/components/image.ts b/apps/scandic-web/types/components/image.ts deleted file mode 100644 index 967067f6f..000000000 --- a/apps/scandic-web/types/components/image.ts +++ /dev/null @@ -1,21 +0,0 @@ -import type { FocalPoint } from "@scandic-hotels/common/utils/imageVault" - -interface Dimensions { - width: number - height: number - aspectRatio: number -} - -interface Meta { - alt: string | undefined | null - caption: string | undefined | null -} - -export interface ApiImage { - id: string - url: string - title: string - meta: Meta - dimensions?: Dimensions - focalPoint?: FocalPoint -} diff --git a/apps/scandic-web/types/components/myPages/stays/button.ts b/apps/scandic-web/types/components/myPages/stays/button.ts deleted file mode 100644 index 43a372879..000000000 --- a/apps/scandic-web/types/components/myPages/stays/button.ts +++ /dev/null @@ -1,4 +0,0 @@ -export type ShowMoreButtonParams = { - disabled?: boolean - loadMoreData: () => void -} diff --git a/packages/design-system/lib/components/Form/utils/index.ts b/packages/design-system/lib/components/Form/utils/index.ts deleted file mode 100644 index 8af5c7c68..000000000 --- a/packages/design-system/lib/components/Form/utils/index.ts +++ /dev/null @@ -1 +0,0 @@ -export { mergeRefs } from "./mergeRefs" diff --git a/packages/design-system/lib/components/Loading/index.tsx b/packages/design-system/lib/components/Loading/index.tsx deleted file mode 100644 index b779bd7f6..000000000 --- a/packages/design-system/lib/components/Loading/index.tsx +++ /dev/null @@ -1 +0,0 @@ -export { Loading } from "./Loading" diff --git a/packages/design-system/lib/components/Progress/variants.ts b/packages/design-system/lib/components/Progress/variants.ts deleted file mode 100644 index 68b776742..000000000 --- a/packages/design-system/lib/components/Progress/variants.ts +++ /dev/null @@ -1,10 +0,0 @@ -import { cva } from "class-variance-authority" - -import styles from "./progress.module.css" - -export const config = { - variants: {}, - defaultVariants: {}, -} as const - -export const variants = cva(styles.progress, config) diff --git a/packages/design-system/lib/tokens.ts b/packages/design-system/lib/tokens.ts deleted file mode 100644 index c9434aae3..000000000 --- a/packages/design-system/lib/tokens.ts +++ /dev/null @@ -1 +0,0 @@ -export * from "./tokens/index"