@eleven-labs/design-system 0.6.3 → 0.10.0
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/components/Atoms/Blockquote/Blockquote.d.ts +4 -3
- package/dist/components/Atoms/Button/Button.d.ts +7 -5
- package/dist/components/Atoms/Icon/Icon.d.ts +1 -1
- package/dist/components/Atoms/Layout/Box/Box.d.ts +7 -3
- package/dist/components/Atoms/Layout/Flex/Flex.d.ts +6 -5
- package/dist/components/Atoms/Logo/Logo.d.ts +5 -4
- package/dist/components/Atoms/Skeleton/Skeleton.d.ts +4 -4
- package/dist/components/Atoms/Svgs/AccessTime.d.ts +2 -2
- package/dist/components/Atoms/Svgs/ArrowBack.d.ts +2 -2
- package/dist/components/Atoms/Svgs/Calendar.d.ts +2 -2
- package/dist/components/Atoms/Svgs/Close.d.ts +2 -2
- package/dist/components/Atoms/Svgs/Facebook.d.ts +2 -2
- package/dist/components/Atoms/Svgs/Github.d.ts +2 -2
- package/dist/components/Atoms/Svgs/Language.d.ts +2 -2
- package/dist/components/Atoms/Svgs/Link.d.ts +2 -2
- package/dist/components/Atoms/Svgs/Linkedin.d.ts +2 -2
- package/dist/components/Atoms/Svgs/Logo.d.ts +2 -2
- package/dist/components/Atoms/Svgs/Message.d.ts +2 -2
- package/dist/components/Atoms/Svgs/Person.d.ts +2 -2
- package/dist/components/Atoms/Svgs/Rss.d.ts +2 -2
- package/dist/components/Atoms/Svgs/Search.d.ts +2 -2
- package/dist/components/Atoms/Svgs/Tuto.d.ts +2 -2
- package/dist/components/Atoms/Svgs/Twitter.d.ts +2 -2
- package/dist/components/Atoms/Svgs/Welcometothejungle.d.ts +2 -2
- package/dist/components/Atoms/Svgs/index.d.ts +17 -17
- package/dist/components/Atoms/SyntaxHighlighter/SyntaxHighlighter.d.ts +2 -2
- package/dist/components/Atoms/Typography/Heading/Heading.d.ts +5 -4
- package/dist/components/Atoms/Typography/Text/Text.d.ts +5 -4
- package/dist/components/Molecules/Link/Link.d.ts +7 -6
- package/dist/components/Molecules/Reminder/Reminder.d.ts +4 -5
- package/dist/components/Molecules/SearchField/SearchField.d.ts +8 -9
- package/dist/components/Molecules/TextHighlight/TextHighlight.d.ts +5 -6
- package/dist/constants/systemProps/systemProps.d.ts +1 -1
- package/dist/constants/tokenVariables.d.ts +1 -1
- package/dist/helpers/index.d.ts +1 -0
- package/dist/helpers/polyRef.d.ts +2 -0
- package/dist/helpers/stringHelper.d.ts +3 -3
- package/dist/helpers/systemPropsHelper/classNamesWithModifiers.d.ts +1 -1
- package/dist/helpers/systemPropsHelper/hiddenSystemClassName.d.ts +1 -1
- package/dist/helpers/systemPropsHelper/index.d.ts +0 -1
- package/dist/helpers/systemPropsHelper/systemClassName.d.ts +1 -1
- package/dist/helpers/systemPropsHelper/typographySystemClassName.d.ts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.es.js +844 -1002
- package/dist/index.umd.cjs +9 -9
- package/dist/scss/abstracts/variables/_token-variables.scss +1 -1
- package/dist/scss/abstracts/variables/_variables.scss +1 -1
- package/dist/types/MediaQueryType.d.ts +1 -1
- package/dist/types/SystemProps/FlexBoxSystemProps.d.ts +1 -1
- package/dist/types/SystemProps/HiddenSystemProps.d.ts +1 -1
- package/dist/types/SystemProps/LayoutSystemProps.d.ts +1 -1
- package/dist/types/SystemProps/SystemProps.d.ts +2 -2
- package/dist/types/SystemProps/index.d.ts +0 -2
- package/dist/types/TypeWithModifier.d.ts +1 -1
- package/dist/types/cssPropertyTypes.d.ts +1 -1
- package/dist/types/tokenTypes.d.ts +1 -1
- package/package.json +8 -10
- package/dist/helpers/systemPropsHelper/forwardRef.d.ts +0 -7
- package/dist/types/SystemProps/AsProps.d.ts +0 -4
- package/dist/types/SystemProps/ComponentWithAs.d.ts +0 -16
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { mediaQueriesList } from '../constants';
|
|
1
|
+
import type { mediaQueriesList } from '../constants';
|
|
2
2
|
export type MediaQueryType = (typeof mediaQueriesList)[number];
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { AlignContentType, AlignItemsType, FlexType, JustifyContentType, SpacingType, TypeWithMediaQueriesType } from '../../types';
|
|
2
|
-
import { AlignSelfType, FlexBasisType, FlexDirectionType, FlexWrapType } from '../../types';
|
|
2
|
+
import type { AlignSelfType, FlexBasisType, FlexDirectionType, FlexWrapType } from '../../types';
|
|
3
3
|
export interface FlexBoxSystemProps {
|
|
4
4
|
/**
|
|
5
5
|
* flex-direction (including breakpoints modifiers)
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { DisplayType, HeightType, TypeWithMediaQueriesType, WidthType } from '../../types';
|
|
1
|
+
import type { DisplayType, HeightType, TypeWithMediaQueriesType, WidthType } from '../../types';
|
|
2
2
|
export interface LayoutSystemProps {
|
|
3
3
|
/**
|
|
4
4
|
* display (including breakpoints modifiers)
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import type { ColorSystemProps,
|
|
2
|
-
export interface SystemProps extends ColorSystemProps,
|
|
1
|
+
import type { ColorSystemProps, HiddenSystemProps, LayoutSystemProps, SpacingSystemProps } from '../../types';
|
|
2
|
+
export interface SystemProps extends ColorSystemProps, LayoutSystemProps, SpacingSystemProps, HiddenSystemProps {
|
|
3
3
|
}
|
|
@@ -3,7 +3,5 @@ export * from './SpacingSystemProps';
|
|
|
3
3
|
export * from './SystemProps';
|
|
4
4
|
export * from './TypographySystemProps';
|
|
5
5
|
export * from './FlexBoxSystemProps';
|
|
6
|
-
export * from './AsProps';
|
|
7
6
|
export * from './LayoutSystemProps';
|
|
8
|
-
export * from './ComponentWithAs';
|
|
9
7
|
export * from './HiddenSystemProps';
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { MediaQueryType } from '../types/MediaQueryType';
|
|
1
|
+
import type { MediaQueryType } from '../types/MediaQueryType';
|
|
2
2
|
export type TypeWithModifierType<TModifierType extends string, TPropValue> = Partial<Record<TModifierType, TPropValue>>;
|
|
3
3
|
export type TypeWithMediaQueriesType<T> = T | TypeWithModifierType<MediaQueryType, T>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { cssProperties } from '../constants';
|
|
1
|
+
import type { cssProperties } from '../constants';
|
|
2
2
|
export type TextAlignType = keyof (typeof cssProperties)['text-align'];
|
|
3
3
|
export type TextTransformType = keyof (typeof cssProperties)['text-transform'];
|
|
4
4
|
export type DisplayType = keyof (typeof cssProperties)['display'];
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { tokenVariables } from '../constants';
|
|
1
|
+
import type { tokenVariables } from '../constants';
|
|
2
2
|
export type ColorType = keyof (typeof tokenVariables)['color']['primary'] | keyof (typeof tokenVariables)['color']['secondary'] | keyof (typeof tokenVariables)['color']['greyscale'];
|
|
3
3
|
export type SpacingType = keyof (typeof tokenVariables)['spacing'];
|
|
4
4
|
export type WidthType = keyof (typeof tokenVariables)['width'];
|
package/package.json
CHANGED
|
@@ -1,18 +1,13 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@eleven-labs/design-system",
|
|
3
3
|
"description": "Design System for Eleven Labs",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.10.0",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
7
7
|
"url": "https://github.com/eleven-labs/design-system.git"
|
|
8
8
|
},
|
|
9
9
|
"author": "Eleven Labs <contact@eleven-labs.com>",
|
|
10
10
|
"license": "MIT",
|
|
11
|
-
"keywords": [
|
|
12
|
-
"eslint",
|
|
13
|
-
"lint",
|
|
14
|
-
"prettier"
|
|
15
|
-
],
|
|
16
11
|
"type": "module",
|
|
17
12
|
"main": "./dist/index.umd.cjs",
|
|
18
13
|
"module": "./dist/index.es.js",
|
|
@@ -39,7 +34,7 @@
|
|
|
39
34
|
"start:storybook": "storybook dev -p 6009",
|
|
40
35
|
"build:storybook": "yarn build && yarn storybook build",
|
|
41
36
|
"lint:style": "stylelint 'src/**/*.scss'",
|
|
42
|
-
"lint:es": "eslint --ext .ts,.tsx src
|
|
37
|
+
"lint:es": "eslint --ext .ts,.tsx src",
|
|
43
38
|
"lint": "yarn lint:style && yarn lint:es",
|
|
44
39
|
"test": "jest"
|
|
45
40
|
},
|
|
@@ -56,9 +51,11 @@
|
|
|
56
51
|
"yarn": ">= 1.2.0",
|
|
57
52
|
"node": ">= 14.0"
|
|
58
53
|
},
|
|
54
|
+
"prettier": "@eleven-labs/prettier-config",
|
|
59
55
|
"dependencies": {
|
|
60
56
|
"autosuggest-highlight": "^3.3.4",
|
|
61
57
|
"classnames": "^2.3.2",
|
|
58
|
+
"react-polymorphed": "^2.2.1",
|
|
62
59
|
"react-syntax-highlighter": "^15.5.0"
|
|
63
60
|
},
|
|
64
61
|
"peerDependencies": {
|
|
@@ -68,7 +65,8 @@
|
|
|
68
65
|
"devDependencies": {
|
|
69
66
|
"@commitlint/cli": "^17.6.5",
|
|
70
67
|
"@commitlint/config-conventional": "^17.6.5",
|
|
71
|
-
"@
|
|
68
|
+
"@eleven-labs/eslint-config": "^1.0.0",
|
|
69
|
+
"@eleven-labs/prettier-config": "^1.0.0",
|
|
72
70
|
"@storybook/addon-actions": "^7.0.22",
|
|
73
71
|
"@storybook/addon-essentials": "^7.0.22",
|
|
74
72
|
"@storybook/addon-interactions": "^7.0.22",
|
|
@@ -84,7 +82,7 @@
|
|
|
84
82
|
"@types/react-syntax-highlighter": "^15.5.7",
|
|
85
83
|
"@vitejs/plugin-react": "^4.0.1",
|
|
86
84
|
"autoprefixer": "^10.4.14",
|
|
87
|
-
"eslint": "^8.
|
|
85
|
+
"eslint": "^8.52.0",
|
|
88
86
|
"husky": "^8.0.3",
|
|
89
87
|
"jest": "^29.5.0",
|
|
90
88
|
"lint-staged": "^13.2.2",
|
|
@@ -92,7 +90,7 @@
|
|
|
92
90
|
"postcss": "^8.4.24",
|
|
93
91
|
"postcss-normalize": "^10.0.1",
|
|
94
92
|
"postcss-scss": "^4.0.6",
|
|
95
|
-
"prettier": "^
|
|
93
|
+
"prettier": "^3.0.3",
|
|
96
94
|
"react": "^18.2.0",
|
|
97
95
|
"react-dom": "^18.2.0",
|
|
98
96
|
"rollup-plugin-peer-deps-external": "^2.2.4",
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { As, ComponentWithAs, PropsOf, RightJoinProps } from '../../types';
|
|
3
|
-
export declare function forwardRef<Props extends object, Component extends As>(component: React.ForwardRefRenderFunction<any, // eslint-disable-line @typescript-eslint/no-explicit-any
|
|
4
|
-
// eslint-disable-line @typescript-eslint/no-explicit-any
|
|
5
|
-
RightJoinProps<PropsOf<Component>, Props> & {
|
|
6
|
-
as?: As;
|
|
7
|
-
}>): ComponentWithAs<Component, Props>;
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
export type As<Props = any> = React.ElementType<Props>;
|
|
2
|
-
/**
|
|
3
|
-
* Extract the props of a React element or component
|
|
4
|
-
*/
|
|
5
|
-
export type PropsOf<T extends As> = React.ComponentPropsWithoutRef<T> & {
|
|
6
|
-
as?: As;
|
|
7
|
-
};
|
|
8
|
-
export type OmitCommonProps<Target, OmitAdditionalProps extends keyof any = never> = Omit<Target, 'as' | 'color' | OmitAdditionalProps>;
|
|
9
|
-
export type RightJoinProps<SourceProps extends object = {}, OverrideProps extends object = {}> = OmitCommonProps<SourceProps, keyof OverrideProps> & OverrideProps;
|
|
10
|
-
export type MergeWithAs<ComponentProps extends object, AsProps extends object, AdditionalProps extends object = {}, AsComponent extends As = As> = RightJoinProps<ComponentProps, AdditionalProps> & RightJoinProps<AsProps, AdditionalProps> & {
|
|
11
|
-
as?: AsComponent;
|
|
12
|
-
};
|
|
13
|
-
export type ComponentWithAs<Component extends As, Props extends object = {}> = {
|
|
14
|
-
<AsComponent extends As = Component>(props: MergeWithAs<React.ComponentProps<Component>, React.ComponentProps<AsComponent>, Props, AsComponent>): JSX.Element;
|
|
15
|
-
displayName?: string;
|
|
16
|
-
};
|