@norges-domstoler/dds-components 13.6.2 → 13.6.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/components/AppShell/AppShell.d.ts +13 -0
- package/dist/cjs/components/AppShell/AppShell.stories.d.ts +23 -0
- package/dist/cjs/components/AppShell/AppShell.tokens.d.ts +68 -0
- package/dist/cjs/components/AppShell/Navigation/Navigation.d.ts +8 -0
- package/dist/cjs/components/AppShell/Navigation/NavigationItem.d.ts +17 -0
- package/dist/cjs/components/AppShell/index.d.ts +7 -0
- package/dist/cjs/components/List/List.stories.d.ts +3 -3
- package/dist/cjs/index.d.ts +1 -0
- package/dist/cjs/index.js +372 -171
- package/dist/components/AppShell/AppShell.d.ts +13 -0
- package/dist/components/AppShell/AppShell.js +27 -0
- package/dist/components/AppShell/AppShell.stories.d.ts +23 -0
- package/dist/components/AppShell/AppShell.tokens.d.ts +68 -0
- package/dist/components/AppShell/AppShell.tokens.js +55 -0
- package/dist/components/AppShell/Navigation/Navigation.d.ts +8 -0
- package/dist/components/AppShell/Navigation/Navigation.js +68 -0
- package/dist/components/AppShell/Navigation/NavigationItem.d.ts +17 -0
- package/dist/components/AppShell/Navigation/NavigationItem.js +70 -0
- package/dist/components/AppShell/index.d.ts +7 -0
- package/dist/components/AppShell/index.js +7 -0
- package/dist/components/List/List.stories.d.ts +3 -3
- package/dist/index.d.ts +1 -0
- package/dist/index.js +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { PropsWithChildren, ReactElement } from 'react';
|
|
2
|
+
export type AppShellProps = PropsWithChildren<{
|
|
3
|
+
/**Versjon på appen på formatet 0.0.0 */
|
|
4
|
+
version?: string;
|
|
5
|
+
navigation: AppShellNavigationProps;
|
|
6
|
+
}>;
|
|
7
|
+
export type AppShellNavigationProps = {
|
|
8
|
+
/**Interne lenker i navigasjonen. */
|
|
9
|
+
internal?: ReactElement[];
|
|
10
|
+
/**Eksterne lenker i navigasjonen. */
|
|
11
|
+
external?: ReactElement[];
|
|
12
|
+
};
|
|
13
|
+
export declare const AppShell: ({ children, version, navigation: { internal, external }, }: AppShellProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { ComponentProps } from 'react';
|
|
2
|
+
import { AppShell } from '.';
|
|
3
|
+
declare const _default: {
|
|
4
|
+
title: string;
|
|
5
|
+
component: (({ children, version, navigation: { internal, external }, }: import("./AppShell").AppShellProps) => import("react/jsx-runtime").JSX.Element) & {
|
|
6
|
+
NavItem: {
|
|
7
|
+
<T extends import("@norges-domstoler/dds-core").As = "a">({ as: _as, active, icon, external, children, ...rest }: import("react").PropsWithoutRef<ComponentProps<T>> & {
|
|
8
|
+
as?: T | undefined;
|
|
9
|
+
} & ({
|
|
10
|
+
icon: import("@norges-domstoler/dds-icons").SvgIcon;
|
|
11
|
+
active?: boolean | undefined;
|
|
12
|
+
external?: false | undefined;
|
|
13
|
+
} | {
|
|
14
|
+
external: true;
|
|
15
|
+
active?: false | undefined;
|
|
16
|
+
icon?: undefined;
|
|
17
|
+
})): import("react/jsx-runtime").JSX.Element;
|
|
18
|
+
displayName: string;
|
|
19
|
+
};
|
|
20
|
+
};
|
|
21
|
+
};
|
|
22
|
+
export default _default;
|
|
23
|
+
export declare const Default: (args: ComponentProps<typeof AppShell>) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
export declare const appShellTokens: {
|
|
2
|
+
navigation: {
|
|
3
|
+
navigationItems: {
|
|
4
|
+
gap: string;
|
|
5
|
+
item: {
|
|
6
|
+
color: string;
|
|
7
|
+
borderRadius: string;
|
|
8
|
+
padding: string;
|
|
9
|
+
gap: string;
|
|
10
|
+
external: {
|
|
11
|
+
lineHeight: any;
|
|
12
|
+
fontSize: string;
|
|
13
|
+
letterSpacing: any;
|
|
14
|
+
fontFamily: any;
|
|
15
|
+
fontWeight: any;
|
|
16
|
+
fontStyle: any;
|
|
17
|
+
};
|
|
18
|
+
hover: {
|
|
19
|
+
backgroundColor: string;
|
|
20
|
+
};
|
|
21
|
+
active: {
|
|
22
|
+
color: string;
|
|
23
|
+
backgroundColor: string;
|
|
24
|
+
};
|
|
25
|
+
lineHeight: any;
|
|
26
|
+
fontSize: string;
|
|
27
|
+
letterSpacing: any;
|
|
28
|
+
fontFamily: any;
|
|
29
|
+
fontWeight: any;
|
|
30
|
+
fontStyle: any;
|
|
31
|
+
};
|
|
32
|
+
};
|
|
33
|
+
logoAndVersion: {
|
|
34
|
+
padding: string;
|
|
35
|
+
color: string;
|
|
36
|
+
logo: {
|
|
37
|
+
fontWeight: number;
|
|
38
|
+
lineHeight: any;
|
|
39
|
+
fontSize: string;
|
|
40
|
+
letterSpacing: any;
|
|
41
|
+
fontFamily: any;
|
|
42
|
+
fontStyle: any;
|
|
43
|
+
};
|
|
44
|
+
version: {
|
|
45
|
+
lineHeight: any;
|
|
46
|
+
fontSize: string;
|
|
47
|
+
letterSpacing: any;
|
|
48
|
+
fontFamily: any;
|
|
49
|
+
fontWeight: any;
|
|
50
|
+
fontStyle: any;
|
|
51
|
+
};
|
|
52
|
+
};
|
|
53
|
+
color: string;
|
|
54
|
+
backgroundColor: string;
|
|
55
|
+
gap: string;
|
|
56
|
+
dividerColor: string;
|
|
57
|
+
padding: string;
|
|
58
|
+
width: string;
|
|
59
|
+
mobile: {
|
|
60
|
+
iconColors: string;
|
|
61
|
+
};
|
|
62
|
+
};
|
|
63
|
+
floatingActionButtons: {
|
|
64
|
+
gap: string;
|
|
65
|
+
textColor: string;
|
|
66
|
+
backgroundColor: string;
|
|
67
|
+
};
|
|
68
|
+
};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { ReactElement } from 'react';
|
|
2
|
+
export declare const NavigationItems: import("styled-components").StyledComponent<"nav", any, {}, never>;
|
|
3
|
+
export type NavigationProps = {
|
|
4
|
+
version: string;
|
|
5
|
+
internal: ReactElement[];
|
|
6
|
+
external: ReactElement[];
|
|
7
|
+
};
|
|
8
|
+
export declare const Navigation: ({ version, internal, external, }: NavigationProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { type PropsOf, type As } from '@norges-domstoler/dds-core';
|
|
2
|
+
import { SvgIcon } from '@norges-domstoler/dds-icons';
|
|
3
|
+
type BaseNavigationItemProps = {
|
|
4
|
+
icon: SvgIcon;
|
|
5
|
+
active?: boolean;
|
|
6
|
+
external?: undefined | false;
|
|
7
|
+
} | {
|
|
8
|
+
external: true;
|
|
9
|
+
active?: undefined | false;
|
|
10
|
+
icon?: undefined;
|
|
11
|
+
};
|
|
12
|
+
type NavigationItemProps<T extends As = 'a'> = PropsOf<T> & BaseNavigationItemProps;
|
|
13
|
+
export declare const NavigationItem: {
|
|
14
|
+
<T extends As = "a">({ as: _as, active, icon, external, children, ...rest }: NavigationItemProps<T>): import("react/jsx-runtime").JSX.Element;
|
|
15
|
+
displayName: string;
|
|
16
|
+
};
|
|
17
|
+
export {};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { AppShell as BaseAppShell, AppShellProps } from './AppShell';
|
|
2
|
+
import { NavigationItem } from './Navigation/NavigationItem';
|
|
3
|
+
type CompoundAppShell = typeof BaseAppShell & {
|
|
4
|
+
NavItem: typeof NavigationItem;
|
|
5
|
+
};
|
|
6
|
+
declare const AppShell: CompoundAppShell;
|
|
7
|
+
export { AppShell, type AppShellProps };
|
|
@@ -2,14 +2,14 @@
|
|
|
2
2
|
import { ListProps } from '.';
|
|
3
3
|
declare const _default: {
|
|
4
4
|
title: string;
|
|
5
|
-
component: import("react").ForwardRefExoticComponent<Pick<import("react").HTMLAttributes<
|
|
5
|
+
component: import("react").ForwardRefExoticComponent<Pick<import("react").HTMLAttributes<HTMLOListElement | HTMLUListElement>, "className" | "id"> & {
|
|
6
6
|
listType?: import("./List").ListType | undefined;
|
|
7
7
|
typographyType?: import("./List").ListTypographyType | undefined;
|
|
8
8
|
} & {
|
|
9
9
|
children?: import("react").ReactNode;
|
|
10
10
|
} & {
|
|
11
|
-
htmlProps?: import("react").HTMLAttributes<
|
|
12
|
-
} & import("react").RefAttributes<
|
|
11
|
+
htmlProps?: import("react").HTMLAttributes<HTMLOListElement | HTMLUListElement> | undefined;
|
|
12
|
+
} & import("react").RefAttributes<HTMLOListElement | HTMLUListElement>>;
|
|
13
13
|
};
|
|
14
14
|
export default _default;
|
|
15
15
|
export declare const Overview: (args: ListProps) => import("react/jsx-runtime").JSX.Element;
|
package/dist/cjs/index.d.ts
CHANGED
|
@@ -5,6 +5,7 @@ export * from './dds-core';
|
|
|
5
5
|
export * from './dds-form';
|
|
6
6
|
export * from './dds-icons';
|
|
7
7
|
export * from './dds-typography';
|
|
8
|
+
export * from './components/AppShell';
|
|
8
9
|
export * from './components/SelectionControl/RadioButton';
|
|
9
10
|
export * from './components/SelectionControl/Checkbox';
|
|
10
11
|
export * from './components/Button';
|