@edvisor/product-language 0.1.0 → 0.1.1

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.
Files changed (231) hide show
  1. package/index.d.ts +2 -0
  2. package/index.js +6078 -0
  3. package/lib/components/alert-banner/alert-banner.d.ts +11 -0
  4. package/lib/components/alert-banner/alert-level-flags.d.ts +13 -0
  5. package/lib/components/alert-banner/index.d.ts +1 -0
  6. package/lib/components/badge/badge-type-flags.d.ts +18 -0
  7. package/lib/components/badge/badge.d.ts +5 -0
  8. package/lib/components/badge/index.d.ts +1 -0
  9. package/{src/lib/components/card/atoms/card-frame.tsx → lib/components/card/atoms/card-frame.d.ts} +7 -17
  10. package/lib/components/card/atoms/index.d.ts +1 -0
  11. package/lib/components/card/card.d.ts +14 -0
  12. package/lib/components/card/components/card-alert-banner-slot.d.ts +5 -0
  13. package/lib/components/card/components/card-controls-slot.d.ts +4 -0
  14. package/lib/components/card/components/card-section-slot.d.ts +11 -0
  15. package/lib/components/card/components/index.d.ts +3 -0
  16. package/lib/components/card/index.d.ts +2 -0
  17. package/lib/components/card/molecules/index.d.ts +1 -0
  18. package/lib/components/card/molecules/left-right-card.d.ts +16 -0
  19. package/lib/components/checkbox/checkbox.d.ts +11 -0
  20. package/lib/components/checkbox/components/components.d.ts +12 -0
  21. package/lib/components/checkbox/index.d.ts +1 -0
  22. package/lib/components/divider/divider-type-flags.d.ts +9 -0
  23. package/lib/components/divider/divider.d.ts +7 -0
  24. package/lib/components/divider/index.d.ts +1 -0
  25. package/lib/components/index.d.ts +12 -0
  26. package/lib/components/input-field/components/index.d.ts +2 -0
  27. package/lib/components/input-field/components/labeled-input.d.ts +11 -0
  28. package/lib/components/input-field/components/stepper.d.ts +7 -0
  29. package/lib/components/input-field/index.d.ts +3 -0
  30. package/lib/components/input-field/input-field.d.ts +25 -0
  31. package/lib/components/input-field/input-number.d.ts +18 -0
  32. package/lib/components/input-field/input-text.d.ts +14 -0
  33. package/lib/components/layout/flex.d.ts +16 -0
  34. package/lib/components/layout/grid-layout.d.ts +11 -0
  35. package/lib/components/layout/index.d.ts +3 -0
  36. package/lib/components/layout/left-right-layout.d.ts +70 -0
  37. package/lib/components/link/index.d.ts +1 -0
  38. package/lib/components/link/link.d.ts +14 -0
  39. package/lib/components/molecules/avatar/avatar-size-flags.d.ts +12 -0
  40. package/lib/components/molecules/avatar/avatar.d.ts +12 -0
  41. package/lib/components/molecules/avatar/index.d.ts +1 -0
  42. package/lib/components/molecules/button/button-flags.d.ts +39 -0
  43. package/lib/components/molecules/button/button.d.ts +24 -0
  44. package/lib/components/molecules/button/index.d.ts +1 -0
  45. package/lib/components/molecules/index.d.ts +3 -0
  46. package/lib/components/molecules/input-checkbox/index.d.ts +1 -0
  47. package/lib/components/molecules/input-checkbox/input-checkbox.d.ts +8 -0
  48. package/lib/components/organisms/index.d.ts +1 -0
  49. package/lib/components/organisms/multi-choice-list/index.d.ts +1 -0
  50. package/lib/components/organisms/multi-choice-list/multi-choice-list.d.ts +11 -0
  51. package/lib/components/spinner/index.d.ts +1 -0
  52. package/lib/components/spinner/spinner-size-flags.d.ts +10 -0
  53. package/lib/components/spinner/spinner.d.ts +9 -0
  54. package/lib/components/thumbnail/index.d.ts +1 -0
  55. package/lib/components/thumbnail/thumbnail-size-flags.d.ts +10 -0
  56. package/lib/components/thumbnail/thumbnail.d.ts +9 -0
  57. package/lib/components/typography/index.d.ts +1 -0
  58. package/lib/components/typography/typography.d.ts +23 -0
  59. package/lib/foundations/color-system/base-palette/base-palette.d.ts +77 -0
  60. package/lib/foundations/color-system/base-palette/index.d.ts +1 -0
  61. package/lib/foundations/color-system/color-guidelines/color-guidelines.d.ts +131 -0
  62. package/lib/foundations/color-system/color-guidelines/index.d.ts +1 -0
  63. package/lib/foundations/color-system/components/color-sample.d.ts +17 -0
  64. package/lib/foundations/color-system/components/index.d.ts +1 -0
  65. package/lib/foundations/color-system/index.d.ts +1 -0
  66. package/lib/foundations/index.d.ts +4 -0
  67. package/lib/foundations/shadows/components.d.ts +8 -0
  68. package/lib/foundations/shadows/index.d.ts +1 -0
  69. package/lib/foundations/shadows/shadows.d.ts +8 -0
  70. package/lib/foundations/spacing/index.d.ts +1 -0
  71. package/lib/foundations/spacing/spacing-guidelines.d.ts +22 -0
  72. package/lib/foundations/spacing/spacing.d.ts +18 -0
  73. package/lib/foundations/typography/constants.d.ts +22 -0
  74. package/lib/foundations/typography/index.d.ts +1 -0
  75. package/lib/foundations/typography/text-aspect-flags.d.ts +14 -0
  76. package/lib/foundations/typography/typography.d.ts +19 -0
  77. package/lib/helpers/generic-types.d.ts +21 -0
  78. package/lib/helpers/index.d.ts +6 -0
  79. package/lib/helpers/nothing.d.ts +8 -0
  80. package/{src/lib/helpers/numbers.ts → lib/helpers/numbers.d.ts} +41 -53
  81. package/lib/helpers/safe-navigation.d.ts +14 -0
  82. package/lib/helpers/slots.d.ts +8 -0
  83. package/lib/helpers/strings.d.ts +1 -0
  84. package/package.json +12 -22
  85. package/release-it.json +18 -0
  86. package/.babelrc +0 -12
  87. package/.eslintrc.json +0 -139
  88. package/.storybook/main.js +0 -57
  89. package/.storybook/manager.js +0 -7
  90. package/.storybook/preview-head.html +0 -1
  91. package/.storybook/preview.js +0 -15
  92. package/.storybook/tsconfig.json +0 -30
  93. package/jest.config.ts +0 -15
  94. package/jest.setup.ts +0 -2
  95. package/project.json +0 -75
  96. package/src/assets/svg/example_icon.svg +0 -3
  97. package/src/assets/svg/example_icon_white.svg +0 -3
  98. package/src/assets/svg/spinner.svg +0 -3
  99. package/src/assets/svg/spinner_white.svg +0 -3
  100. package/src/helpers/index.ts +0 -3
  101. package/src/helpers/talesOf.tsx +0 -42
  102. package/src/index.ts +0 -2
  103. package/src/lib/components/README.md +0 -49
  104. package/src/lib/components/alert-banner/alert-banner.tsx +0 -34
  105. package/src/lib/components/alert-banner/alert-level-flags.ts +0 -77
  106. package/src/lib/components/alert-banner/index.ts +0 -1
  107. package/src/lib/components/badge/badge-type-flags.ts +0 -72
  108. package/src/lib/components/badge/badge.stories.tsx +0 -16
  109. package/src/lib/components/badge/badge.test.tsx +0 -29
  110. package/src/lib/components/badge/badge.tsx +0 -31
  111. package/src/lib/components/badge/index.ts +0 -1
  112. package/src/lib/components/card/atoms/index.ts +0 -1
  113. package/src/lib/components/card/card.test.tsx +0 -163
  114. package/src/lib/components/card/card.tsx +0 -78
  115. package/src/lib/components/card/components/card-alert-banner-slot.tsx +0 -16
  116. package/src/lib/components/card/components/card-controls-slot.tsx +0 -19
  117. package/src/lib/components/card/components/card-section-slot.tsx +0 -51
  118. package/src/lib/components/card/components/index.ts +0 -3
  119. package/src/lib/components/card/index.ts +0 -2
  120. package/src/lib/components/card/molecules/index.ts +0 -1
  121. package/src/lib/components/card/molecules/left-right-card.test.tsx +0 -89
  122. package/src/lib/components/card/molecules/left-right-card.tsx +0 -63
  123. package/src/lib/components/card/storybook/card.stories.mdx +0 -100
  124. package/src/lib/components/card/storybook/components.tsx +0 -240
  125. package/src/lib/components/checkbox/checkbox.test.tsx +0 -39
  126. package/src/lib/components/checkbox/checkbox.tsx +0 -124
  127. package/src/lib/components/checkbox/components/components.tsx +0 -59
  128. package/src/lib/components/checkbox/index.tsx +0 -1
  129. package/src/lib/components/checkbox/stories/checkbox.stories.mdx +0 -54
  130. package/src/lib/components/checkbox/stories/components.tsx +0 -36
  131. package/src/lib/components/checkbox/stories/index.tsx +0 -1
  132. package/src/lib/components/divider/divider-type-flags.tsx +0 -37
  133. package/src/lib/components/divider/divider.test.tsx +0 -34
  134. package/src/lib/components/divider/divider.tsx +0 -37
  135. package/src/lib/components/divider/index.tsx +0 -1
  136. package/src/lib/components/divider/stories/components.tsx +0 -13
  137. package/src/lib/components/divider/stories/divider.stories.mdx +0 -50
  138. package/src/lib/components/index.ts +0 -14
  139. package/src/lib/components/input-field/components/index.ts +0 -2
  140. package/src/lib/components/input-field/components/labeled-input.tsx +0 -61
  141. package/src/lib/components/input-field/components/stepper.tsx +0 -59
  142. package/src/lib/components/input-field/index.ts +0 -6
  143. package/src/lib/components/input-field/input-field.test.tsx +0 -108
  144. package/src/lib/components/input-field/input-field.tsx +0 -126
  145. package/src/lib/components/input-field/input-number.tsx +0 -41
  146. package/src/lib/components/input-field/input-text.tsx +0 -30
  147. package/src/lib/components/input-field/storybook/components.tsx +0 -334
  148. package/src/lib/components/input-field/storybook/input-field.stories.mdx +0 -113
  149. package/src/lib/components/layout/flex.tsx +0 -22
  150. package/src/lib/components/layout/grid-layout.tsx +0 -40
  151. package/src/lib/components/layout/index.ts +0 -3
  152. package/src/lib/components/layout/left-right-layout.tsx +0 -67
  153. package/src/lib/components/link/index.ts +0 -1
  154. package/src/lib/components/link/link.test.tsx +0 -29
  155. package/src/lib/components/link/link.tsx +0 -56
  156. package/src/lib/components/link/storybook/link.stories.mdx +0 -51
  157. package/src/lib/components/molecules/avatar/avatar-size-flags.tsx +0 -55
  158. package/src/lib/components/molecules/avatar/avatar.test.tsx +0 -114
  159. package/src/lib/components/molecules/avatar/avatar.tsx +0 -80
  160. package/src/lib/components/molecules/avatar/index.tsx +0 -1
  161. package/src/lib/components/molecules/avatar/stories/avatar.stories.mdx +0 -55
  162. package/src/lib/components/molecules/avatar/stories/components.tsx +0 -36
  163. package/src/lib/components/molecules/button/button-flags.tsx +0 -235
  164. package/src/lib/components/molecules/button/button.test.tsx +0 -77
  165. package/src/lib/components/molecules/button/button.tsx +0 -231
  166. package/src/lib/components/molecules/button/index.tsx +0 -1
  167. package/src/lib/components/molecules/button/stories/button.stories.mdx +0 -104
  168. package/src/lib/components/molecules/button/stories/components.tsx +0 -86
  169. package/src/lib/components/molecules/index.ts +0 -3
  170. package/src/lib/components/molecules/input-checkbox/index.tsx +0 -1
  171. package/src/lib/components/molecules/input-checkbox/input-checkbox.test.tsx +0 -34
  172. package/src/lib/components/molecules/input-checkbox/input-checkbox.tsx +0 -50
  173. package/src/lib/components/molecules/input-checkbox/stories/components.tsx +0 -36
  174. package/src/lib/components/molecules/input-checkbox/stories/index.tsx +0 -1
  175. package/src/lib/components/molecules/input-checkbox/stories/input-checkbox.stories.mdx +0 -51
  176. package/src/lib/components/organisms/index.ts +0 -1
  177. package/src/lib/components/organisms/multi-choice-list/index.tsx +0 -1
  178. package/src/lib/components/organisms/multi-choice-list/multi-choice-list.test.tsx +0 -33
  179. package/src/lib/components/organisms/multi-choice-list/multi-choice-list.tsx +0 -53
  180. package/src/lib/components/organisms/multi-choice-list/stories/components.tsx +0 -126
  181. package/src/lib/components/organisms/multi-choice-list/stories/index.tsx +0 -1
  182. package/src/lib/components/organisms/multi-choice-list/stories/multi-choice-list.stories.mdx +0 -99
  183. package/src/lib/components/spinner/index.tsx +0 -1
  184. package/src/lib/components/spinner/spinner-size-flags.tsx +0 -39
  185. package/src/lib/components/spinner/spinner.test.tsx +0 -31
  186. package/src/lib/components/spinner/spinner.tsx +0 -67
  187. package/src/lib/components/spinner/stories/components.tsx +0 -8
  188. package/src/lib/components/spinner/stories/spinner.stories.mdx +0 -42
  189. package/src/lib/components/thumbnail/index.tsx +0 -1
  190. package/src/lib/components/thumbnail/stories/thumbnail.stories.mdx +0 -34
  191. package/src/lib/components/thumbnail/thumbnail-size-flags.tsx +0 -41
  192. package/src/lib/components/thumbnail/thumbnail.test.tsx +0 -51
  193. package/src/lib/components/thumbnail/thumbnail.tsx +0 -40
  194. package/src/lib/components/typography/index.ts +0 -1
  195. package/src/lib/components/typography/storybook/components.tsx +0 -256
  196. package/src/lib/components/typography/storybook/typography.stories.mdx +0 -88
  197. package/src/lib/components/typography/typography.test.tsx +0 -93
  198. package/src/lib/components/typography/typography.tsx +0 -57
  199. package/src/lib/foundations/color-system/base-palette/base-palette.stories.tsx +0 -123
  200. package/src/lib/foundations/color-system/base-palette/base-palette.ts +0 -94
  201. package/src/lib/foundations/color-system/base-palette/index.ts +0 -1
  202. package/src/lib/foundations/color-system/color-guidelines/color-guidelines.stories.mdx +0 -85
  203. package/src/lib/foundations/color-system/color-guidelines/color-guidelines.stories.tsx +0 -231
  204. package/src/lib/foundations/color-system/color-guidelines/color-guidelines.ts +0 -159
  205. package/src/lib/foundations/color-system/color-guidelines/index.ts +0 -1
  206. package/src/lib/foundations/color-system/components/color-sample.tsx +0 -99
  207. package/src/lib/foundations/color-system/components/index.ts +0 -1
  208. package/src/lib/foundations/color-system/index.ts +0 -1
  209. package/src/lib/foundations/index.ts +0 -4
  210. package/src/lib/foundations/shadows/components.tsx +0 -59
  211. package/src/lib/foundations/shadows/index.ts +0 -1
  212. package/src/lib/foundations/shadows/shadows.stories.mdx +0 -71
  213. package/src/lib/foundations/shadows/shadows.tsx +0 -47
  214. package/src/lib/foundations/spacing/index.ts +0 -1
  215. package/src/lib/foundations/spacing/spacing-guidelines.ts +0 -24
  216. package/src/lib/foundations/spacing/spacing.stories.mdx +0 -51
  217. package/src/lib/foundations/spacing/spacing.ts +0 -18
  218. package/src/lib/foundations/typography/constants.ts +0 -25
  219. package/src/lib/foundations/typography/index.tsx +0 -1
  220. package/src/lib/foundations/typography/text-aspect-flags.ts +0 -54
  221. package/src/lib/foundations/typography/typography.tsx +0 -97
  222. package/src/lib/helpers/generic-types.ts +0 -44
  223. package/src/lib/helpers/index.ts +0 -6
  224. package/src/lib/helpers/nothing.tsx +0 -18
  225. package/src/lib/helpers/safe-navigation.ts +0 -34
  226. package/src/lib/helpers/slots.tsx +0 -76
  227. package/src/lib/helpers/strings.test.ts +0 -47
  228. package/src/lib/helpers/strings.ts +0 -16
  229. package/tsconfig.json +0 -35
  230. package/tsconfig.lib.json +0 -28
  231. package/tsconfig.spec.json +0 -21
@@ -0,0 +1,11 @@
1
+ import { FC, PropsWithChildren } from '@helpers';
2
+ import { AlertLevelProps } from './alert-level-flags';
3
+ interface IAlertBannerProps extends PropsWithChildren {
4
+ /** @TODO can we get some examples of alert banner in card from figma? */
5
+ inCard?: boolean;
6
+ dismissible?: boolean;
7
+ className?: string;
8
+ }
9
+ export declare type AlertBannerProps = IAlertBannerProps & AlertLevelProps;
10
+ export declare const AlertBanner: FC<AlertBannerProps>;
11
+ export {};
@@ -0,0 +1,13 @@
1
+ import { Hex, MappedEnum, RequireOnlyOne, PropsWithChildren } from '@helpers';
2
+ declare const enum AlertLevel {
3
+ neutral = 1,
4
+ info = 2,
5
+ success = 4,
6
+ warning = 8,
7
+ critical = 16
8
+ }
9
+ declare type AlertLevels<T> = MappedEnum<typeof AlertLevel, T>;
10
+ export declare type AlertLevelProps = Partial<RequireOnlyOne<AlertLevels<boolean>>> & PropsWithChildren;
11
+ export declare function getBackgroundColor(props: AlertLevelProps): Hex;
12
+ export declare function getBorderColor(props: AlertLevelProps): Hex;
13
+ export {};
@@ -0,0 +1 @@
1
+ export * from './alert-banner';
@@ -0,0 +1,18 @@
1
+ import { Hex, PropsWithChildren } from '@helpers';
2
+ declare const enum BadgeType {
3
+ neutral = 1,
4
+ info = 2,
5
+ success = 4,
6
+ warning = 8,
7
+ critical = 16
8
+ }
9
+ export declare type RequireOnlyOne<T, Keys extends keyof T = keyof T> = Pick<T, Exclude<keyof T, Keys>> & {
10
+ [K in Keys]-?: Required<Pick<T, K>> & Partial<Record<Exclude<Keys, K>, undefined>>;
11
+ }[Keys];
12
+ export declare type MappedEnum<E, T> = {
13
+ [key in keyof E]: T;
14
+ };
15
+ declare type BadgeTypes<T> = MappedEnum<typeof BadgeType, T>;
16
+ export declare type BadgeTypeProps = Partial<RequireOnlyOne<BadgeTypes<boolean>>> & PropsWithChildren;
17
+ export declare function getColor(props: BadgeTypeProps): Hex;
18
+ export {};
@@ -0,0 +1,5 @@
1
+ import { BadgeTypeProps } from './badge-type-flags';
2
+ import { FC, PropsWithChildren } from '@helpers';
3
+ declare type IBadgeProps = BadgeTypeProps & PropsWithChildren;
4
+ export declare const Badge: FC<IBadgeProps, {}>;
5
+ export {};
@@ -0,0 +1 @@
1
+ export * from './badge';
@@ -1,17 +1,7 @@
1
-
2
- import styled from 'styled-components'
3
- import { Surface, Margin } from '@foundations'
4
-
5
- /** this is the frame that is used to implement the Card component
6
- * importantly it does not have any padding, which means it can be
7
- * used to implement a broader range of components than just the card.
8
- *
9
- * We might use it to implement the AlertBanner, or put a table in it.
10
- */
11
- export const CardFrame = styled.section`
12
- background: ${Surface.Default.Default};
13
- max-width: 1024px;
14
-
15
- border-radius: 6px;
16
- margin-bottom: ${Margin.m};
17
- `
1
+ /** this is the frame that is used to implement the Card component
2
+ * importantly it does not have any padding, which means it can be
3
+ * used to implement a broader range of components than just the card.
4
+ *
5
+ * We might use it to implement the AlertBanner, or put a table in it.
6
+ */
7
+ export declare const CardFrame: import("styled-components").StyledComponent<"section", any, {}, never>;
@@ -0,0 +1 @@
1
+ export * from './card-frame';
@@ -0,0 +1,14 @@
1
+ import { FC, PropsWithChildren } from '@helpers';
2
+ import { CardAlertBannerSlot, CardControlsSlot, CardHeadingActionSlot, CardSectionSlot } from './components';
3
+ import { HTMLAttributes } from 'react';
4
+ export interface ICardProps extends HTMLAttributes<HTMLDivElement>, PropsWithChildren {
5
+ heading?: string;
6
+ }
7
+ declare const SubComponents: {
8
+ Section: typeof CardSectionSlot;
9
+ Controls: typeof CardControlsSlot;
10
+ HeadingAction: typeof CardHeadingActionSlot;
11
+ AlertBanner: typeof CardAlertBannerSlot;
12
+ };
13
+ export declare const Card: FC<ICardProps, typeof SubComponents>;
14
+ export {};
@@ -0,0 +1,5 @@
1
+ import { Slot } from '@helpers';
2
+ import { AlertBannerProps } from 'components/alert-banner';
3
+ export declare class CardAlertBannerSlot extends Slot<AlertBannerProps> {
4
+ render(): JSX.Element;
5
+ }
@@ -0,0 +1,4 @@
1
+ import { Slot, PropsWithChildren } from '@helpers';
2
+ export declare class CardControlsSlot extends Slot<PropsWithChildren> {
3
+ render(): JSX.Element;
4
+ }
@@ -0,0 +1,11 @@
1
+ import { HTMLAttributes } from 'react';
2
+ import { Slot, PropsWithChildren } from '@helpers';
3
+ export declare class CardHeadingActionSlot extends Slot {
4
+ }
5
+ interface ICardSectionProps extends HTMLAttributes<HTMLDivElement>, PropsWithChildren {
6
+ heading?: string;
7
+ }
8
+ export declare class CardSectionSlot extends Slot<ICardSectionProps> {
9
+ render(): JSX.Element;
10
+ }
11
+ export {};
@@ -0,0 +1,3 @@
1
+ export * from './card-alert-banner-slot';
2
+ export * from './card-controls-slot';
3
+ export * from './card-section-slot';
@@ -0,0 +1,2 @@
1
+ export * from './card';
2
+ export * from './molecules/left-right-card';
@@ -0,0 +1 @@
1
+ export * from './left-right-card';
@@ -0,0 +1,16 @@
1
+ import { FC, Slot } from '@helpers';
2
+ import { ICardProps } from '../card';
3
+ declare class Right extends Slot {
4
+ }
5
+ declare class Controls extends Slot {
6
+ }
7
+ declare type SubComponents = {
8
+ Right: typeof Right;
9
+ Controls: typeof Controls;
10
+ };
11
+ interface ILeftRightCardProps extends ICardProps {
12
+ helpText?: string;
13
+ className?: string;
14
+ }
15
+ export declare const LeftRightCard: FC<ILeftRightCardProps, SubComponents>;
16
+ export {};
@@ -0,0 +1,11 @@
1
+ import { InputHTMLAttributes } from 'react';
2
+ import { FC } from '@helpers';
3
+ export interface ICheckboxProps {
4
+ disabled?: boolean;
5
+ checked?: boolean;
6
+ error?: boolean;
7
+ className?: string;
8
+ onChange?: (value: boolean) => void;
9
+ }
10
+ export declare type IProps = ICheckboxProps & InputHTMLAttributes<HTMLInputElement>;
11
+ export declare const Checkbox: FC<IProps>;
@@ -0,0 +1,12 @@
1
+ interface ICheckedProps {
2
+ checked: boolean;
3
+ }
4
+ export declare const getHoverStyles: () => import("styled-components").FlattenSimpleInterpolation;
5
+ export declare const getDisabledStyles: () => import("styled-components").FlattenInterpolation<import("styled-components").ThemedStyledProps<ICheckedProps, any>>;
6
+ export declare const getInvalidStyles: () => import("styled-components").FlattenInterpolation<import("styled-components").ThemedStyledProps<ICheckedProps, any>>;
7
+ export declare const HiddenCheckbox: import("styled-components").StyledComponent<"input", any, {}, never>;
8
+ export declare const Icon: import("styled-components").StyledComponent<"svg", any, {}, never>;
9
+ export declare const Wrapper: import("styled-components").StyledComponent<"div", any, {}, never>;
10
+ export declare const getTabIndexValue: (disabled: boolean) => number;
11
+ export declare const getCheckedIcon: () => JSX.Element;
12
+ export {};
@@ -0,0 +1 @@
1
+ export * from './checkbox';
@@ -0,0 +1,9 @@
1
+ import { MappedEnum, RequireOnlyOne, PropsWithChildren } from '@helpers';
2
+ declare const enum DividerType {
3
+ default = 1,
4
+ subdued = 2
5
+ }
6
+ declare type DividerTypes<T> = MappedEnum<typeof DividerType, T>;
7
+ export declare type DivideTypeProps = Partial<RequireOnlyOne<DividerTypes<boolean>>> & PropsWithChildren;
8
+ export declare function getColor(props: DivideTypeProps): string;
9
+ export {};
@@ -0,0 +1,7 @@
1
+ import { FC } from '@helpers';
2
+ import { DivideTypeProps } from './divider-type-flags';
3
+ declare type IProps = {
4
+ className?: string;
5
+ } & DivideTypeProps;
6
+ export declare const Divider: FC<IProps>;
7
+ export {};
@@ -0,0 +1 @@
1
+ export * from './divider';
@@ -0,0 +1,12 @@
1
+ export * from './alert-banner';
2
+ export * from './badge';
3
+ export * from './card';
4
+ export * from './checkbox';
5
+ export * from './divider';
6
+ export * from './input-field';
7
+ export * from './layout';
8
+ export * from './link';
9
+ export * from './thumbnail';
10
+ export * from './typography';
11
+ export * from './molecules';
12
+ export * from './organisms';
@@ -0,0 +1,2 @@
1
+ export * from './labeled-input';
2
+ export * from './stepper';
@@ -0,0 +1,11 @@
1
+ import { PropsWithChildren, FC } from '@helpers';
2
+ export declare const Icon: import("styled-components").StyledComponent<"div", any, {}, never>;
3
+ interface ILabeledInputProps extends PropsWithChildren {
4
+ label?: string;
5
+ helpText?: string;
6
+ errors?: {
7
+ message: string;
8
+ }[];
9
+ }
10
+ export declare const LabeledInput: FC<ILabeledInputProps>;
11
+ export {};
@@ -0,0 +1,7 @@
1
+ import { FC } from '@helpers';
2
+ interface IStepperProps {
3
+ onUpClick?: () => void;
4
+ onDownClick?: () => void;
5
+ }
6
+ export declare const Stepper: FC<IStepperProps>;
7
+ export {};
@@ -0,0 +1,3 @@
1
+ export * from './input-field';
2
+ export * from './input-number';
3
+ export * from './input-text';
@@ -0,0 +1,25 @@
1
+ import { InputHTMLAttributes } from 'react';
2
+ import { Slot } from '@helpers';
3
+ import { LabeledInput } from './components';
4
+ export declare const HTMLInput: import("styled-components").StyledComponent<"input", any, {} & import("@foundations").ITextProps, never>;
5
+ declare class IconSlot extends Slot {
6
+ }
7
+ declare class ControlsSlot extends Slot {
8
+ }
9
+ export declare type InputFieldSlots = {
10
+ Icon: typeof IconSlot;
11
+ Controls: typeof ControlsSlot;
12
+ Label: typeof LabeledInput;
13
+ };
14
+ interface IInputFieldProps extends InputHTMLAttributes<HTMLInputElement> {
15
+ invalid?: boolean;
16
+ prefix?: string;
17
+ suffix?: string;
18
+ label?: string;
19
+ }
20
+ export declare const InputField: import("react").ForwardRefExoticComponent<IInputFieldProps & import("react").RefAttributes<HTMLInputElement>> & {
21
+ Icon: typeof IconSlot;
22
+ Controls: typeof ControlsSlot;
23
+ Label: typeof LabeledInput;
24
+ };
25
+ export {};
@@ -0,0 +1,18 @@
1
+ import { FC } from '@helpers';
2
+ import { InputFieldSlots } from './input-field';
3
+ import { Stepper } from './components';
4
+ interface IInputNumberProps {
5
+ value?: number;
6
+ onChange: (change?: number) => void;
7
+ label?: string;
8
+ placeholder?: string;
9
+ invalid?: boolean;
10
+ prefix?: string;
11
+ suffix?: string;
12
+ required?: boolean;
13
+ }
14
+ declare type IInputNumberSlots = InputFieldSlots & {
15
+ Stepper: typeof Stepper;
16
+ };
17
+ export declare const InputNumber: FC<IInputNumberProps, IInputNumberSlots>;
18
+ export {};
@@ -0,0 +1,14 @@
1
+ import { FC } from '@helpers';
2
+ import { InputFieldSlots } from './input-field';
3
+ interface IInputTextProps {
4
+ value: string;
5
+ onChange: (change: string) => void;
6
+ label?: string;
7
+ invalid?: boolean;
8
+ placeholder?: string;
9
+ prefix?: string;
10
+ suffix?: string;
11
+ required?: boolean;
12
+ }
13
+ export declare const InputText: FC<IInputTextProps, InputFieldSlots>;
14
+ export {};
@@ -0,0 +1,16 @@
1
+ export declare const Flex: import("styled-components").StyledComponent<"div", any, {
2
+ column?: boolean | undefined;
3
+ center?: boolean | undefined;
4
+ }, never>;
5
+ export declare const SpaceBetween: import("styled-components").StyledComponent<"div", any, {
6
+ column?: boolean | undefined;
7
+ center?: boolean | undefined;
8
+ }, never>;
9
+ export declare const SpaceAround: import("styled-components").StyledComponent<"div", any, {
10
+ column?: boolean | undefined;
11
+ center?: boolean | undefined;
12
+ }, never>;
13
+ export declare const Center: import("styled-components").StyledComponent<"div", any, {
14
+ column?: boolean | undefined;
15
+ center?: boolean | undefined;
16
+ }, never>;
@@ -0,0 +1,11 @@
1
+ interface IGridLayoutGeneratorProps {
2
+ columns?: number;
3
+ rows?: number;
4
+ columnGutter?: number;
5
+ rowGutter?: number;
6
+ }
7
+ export declare function gridLayoutGenerator(props?: IGridLayoutGeneratorProps): {
8
+ Grid: import("styled-components").StyledComponent<"div", any, {}, never>;
9
+ Cell: import("styled-components").StyledComponent<"div", any, {}, never>;
10
+ };
11
+ export {};
@@ -0,0 +1,3 @@
1
+ export * from './left-right-layout';
2
+ export * from './flex';
3
+ export * from './grid-layout';
@@ -0,0 +1,70 @@
1
+ /// <reference types="react" />
2
+ import { FC } from '@helpers';
3
+ interface ILeftRightLayoutGeneratorProps {
4
+ columns?: number;
5
+ columnGutter?: number;
6
+ rowGutter?: number;
7
+ }
8
+ export declare function leftRightLayoutGenerator(layoutProps?: ILeftRightLayoutGeneratorProps): {
9
+ LeftRightLayout: FC<{
10
+ children?: import("react").ReactNode;
11
+ }, {
12
+ Left: import("styled-components").StyledComponent<"div", any, {}, never>;
13
+ Right: import("styled-components").StyledComponent<"div", any, {}, never>;
14
+ HeadingText: import("styled-components").StyledComponent<"h3", any, {} & ((import("@foundations").ITextProps & {
15
+ children?: import("react").ReactNode;
16
+ }) & {
17
+ semibold?: boolean | undefined;
18
+ }), never>;
19
+ HelpText: import("styled-components").StyledComponent<"div", any, Partial<Pick<import("@helpers").MappedEnum<typeof import("../../foundations/typography/text-aspect-flags").TextAspects, boolean>, never> & Required<Pick<import("@helpers").MappedEnum<typeof import("../../foundations/typography/text-aspect-flags").TextAspects, boolean>, "subdued">> & Partial<Record<"default" | "light" | "critical" | "success" | "onPrimary" | "onCritical", undefined>>> & {
20
+ children?: import("react").ReactNode;
21
+ } & {
22
+ emphasis?: boolean | undefined;
23
+ } & {
24
+ regular?: boolean | undefined;
25
+ } & {
26
+ medium?: boolean | undefined;
27
+ } & {
28
+ subdued: boolean;
29
+ }, "subdued">;
30
+ BodyText: import("styled-components").StyledComponent<"div", any, {} & ((import("@foundations").ITextProps & {
31
+ children?: import("react").ReactNode;
32
+ }) & {
33
+ regular?: boolean | undefined;
34
+ } & {
35
+ medium?: boolean | undefined;
36
+ }), never>;
37
+ }>;
38
+ Layout: FC<{
39
+ children?: import("react").ReactNode;
40
+ }, {
41
+ Left: import("styled-components").StyledComponent<"div", any, {}, never>;
42
+ Right: import("styled-components").StyledComponent<"div", any, {}, never>;
43
+ HeadingText: import("styled-components").StyledComponent<"h3", any, {} & ((import("@foundations").ITextProps & {
44
+ children?: import("react").ReactNode;
45
+ }) & {
46
+ semibold?: boolean | undefined;
47
+ }), never>;
48
+ HelpText: import("styled-components").StyledComponent<"div", any, Partial<Pick<import("@helpers").MappedEnum<typeof import("../../foundations/typography/text-aspect-flags").TextAspects, boolean>, never> & Required<Pick<import("@helpers").MappedEnum<typeof import("../../foundations/typography/text-aspect-flags").TextAspects, boolean>, "subdued">> & Partial<Record<"default" | "light" | "critical" | "success" | "onPrimary" | "onCritical", undefined>>> & {
49
+ children?: import("react").ReactNode;
50
+ } & {
51
+ emphasis?: boolean | undefined;
52
+ } & {
53
+ regular?: boolean | undefined;
54
+ } & {
55
+ medium?: boolean | undefined;
56
+ } & {
57
+ subdued: boolean;
58
+ }, "subdued">;
59
+ BodyText: import("styled-components").StyledComponent<"div", any, {} & ((import("@foundations").ITextProps & {
60
+ children?: import("react").ReactNode;
61
+ }) & {
62
+ regular?: boolean | undefined;
63
+ } & {
64
+ medium?: boolean | undefined;
65
+ }), never>;
66
+ }>;
67
+ Left: import("styled-components").StyledComponent<"div", any, {}, never>;
68
+ Right: import("styled-components").StyledComponent<"div", any, {}, never>;
69
+ };
70
+ export {};
@@ -0,0 +1 @@
1
+ export * from './link';
@@ -0,0 +1,14 @@
1
+ import { AnchorHTMLAttributes } from 'react';
2
+ import { FC } from '@helpers';
3
+ export declare const HTMLAnchor: import("styled-components").StyledComponent<"a", any, {
4
+ disabled: boolean;
5
+ initialColor: string;
6
+ interactionColor: string;
7
+ }, never>;
8
+ interface ILinkProps extends AnchorHTMLAttributes<HTMLAnchorElement> {
9
+ label: string;
10
+ subtle?: boolean;
11
+ disabled?: boolean;
12
+ }
13
+ export declare const Link: FC<ILinkProps>;
14
+ export {};
@@ -0,0 +1,12 @@
1
+ /// <reference types="react" />
2
+ import { MappedEnum, RequireOnlyOne, PropsWithChildren } from '@helpers';
3
+ declare const enum AvatarSize {
4
+ small = 1,
5
+ medium = 2,
6
+ large = 4
7
+ }
8
+ declare type AvatarSizes<T> = MappedEnum<typeof AvatarSize, T>;
9
+ export declare type AvatarSizeProps = Partial<RequireOnlyOne<AvatarSizes<boolean>>> & PropsWithChildren;
10
+ export declare function getValuesBySize(props: AvatarSizeProps): string;
11
+ export declare function getNodeToRenderText(props: AvatarSizeProps): React.ElementType;
12
+ export {};
@@ -0,0 +1,12 @@
1
+ import { FC } from '@helpers';
2
+ import { AvatarSizeProps } from './avatar-size-flags';
3
+ interface IAvatarProps {
4
+ name: string;
5
+ imageUrl?: string;
6
+ imageLabel?: string;
7
+ withLabel?: boolean;
8
+ className?: string;
9
+ }
10
+ declare type IProps = IAvatarProps & AvatarSizeProps;
11
+ export declare const Avatar: FC<IProps>;
12
+ export {};
@@ -0,0 +1 @@
1
+ export * from './avatar';
@@ -0,0 +1,39 @@
1
+ import { MappedEnum, RequireOnlyOne, PropsWithChildren } from '@helpers';
2
+ export declare const enum ButtonType {
3
+ basic = 1,
4
+ primary = 2,
5
+ primaryDestructive = 4,
6
+ destructive = 8,
7
+ outline = 16,
8
+ plain = 32,
9
+ plainSubtle = 64
10
+ }
11
+ declare const enum ButtonSize {
12
+ default = 1,
13
+ small = 2,
14
+ large = 4
15
+ }
16
+ declare const enum ButtonDisabledType {
17
+ enabled = 1,
18
+ disabled = 2
19
+ }
20
+ declare type ButtonTypes<T> = MappedEnum<typeof ButtonType, T>;
21
+ declare type ButtonSizes<T> = MappedEnum<typeof ButtonSize, T>;
22
+ declare type ButtonDisabledTypes<T> = MappedEnum<typeof ButtonDisabledType, T>;
23
+ export declare type ButtonTypeProps = Partial<RequireOnlyOne<ButtonTypes<boolean>>> & PropsWithChildren;
24
+ export declare type ButtonSizeProps = Partial<RequireOnlyOne<ButtonSizes<boolean>>> & PropsWithChildren;
25
+ export declare type ButtonDisabledTypeProps = Partial<RequireOnlyOne<ButtonDisabledTypes<boolean>>> & PropsWithChildren;
26
+ export declare function getBackgroundColorByType(type: ButtonType): string;
27
+ export declare function getBackgroundColorHoverByType(type: ButtonType): string;
28
+ export declare function getBackgroundColorDisabledByType(type: ButtonType): string;
29
+ export declare function getBackgroundColorPressedByType(type: ButtonType): string;
30
+ export declare function getTextColorByType(type: ButtonType): string;
31
+ export declare function getTextColorOnHoverByType(type: ButtonType): string;
32
+ export declare function getBorderByType(type: ButtonType): string;
33
+ export declare function getBorderDisabledByType(type: ButtonType): string;
34
+ export declare function getPaddingBySize(props: ButtonSizeProps): string;
35
+ export declare function getPaddingByType(type: ButtonType): string;
36
+ export declare function getTextColorIfDisabled(props: ButtonDisabledTypeProps): string;
37
+ export declare function getCursor(props: ButtonDisabledTypeProps): string;
38
+ export declare function getIsDisabled(props: ButtonDisabledTypeProps): boolean;
39
+ export {};
@@ -0,0 +1,24 @@
1
+ import { FC } from '@helpers';
2
+ import { ButtonType } from './button-flags';
3
+ import { ComponentType } from 'react';
4
+ interface DummyIconProps {
5
+ type: ButtonType;
6
+ }
7
+ interface IButtonProps {
8
+ loading?: boolean;
9
+ IconPrefix?: ComponentType<DummyIconProps>;
10
+ IconSuffix?: ComponentType<DummyIconProps>;
11
+ children?: string;
12
+ }
13
+ interface IButtonDestructiveProps extends IButtonProps {
14
+ primary?: boolean;
15
+ }
16
+ interface IButtonPlainProps extends IButtonProps {
17
+ subtle?: boolean;
18
+ }
19
+ export declare const ButtonBasic: FC<IButtonProps>;
20
+ export declare const ButtonPrimary: FC<IButtonProps>;
21
+ export declare const ButtonDestructive: FC<IButtonDestructiveProps>;
22
+ export declare const ButtonOutline: FC<IButtonProps>;
23
+ export declare const ButtonPlain: FC<IButtonPlainProps>;
24
+ export {};
@@ -0,0 +1 @@
1
+ export * from './button';
@@ -0,0 +1,3 @@
1
+ export * from './avatar';
2
+ export * from './button';
3
+ export * from './input-checkbox';
@@ -0,0 +1 @@
1
+ export * from './input-checkbox';
@@ -0,0 +1,8 @@
1
+ import { FC } from '@helpers';
2
+ import { ICheckboxProps } from '../../checkbox';
3
+ interface IInputCheckboxProps {
4
+ label: string;
5
+ }
6
+ export declare type IInputCheckbox = IInputCheckboxProps & ICheckboxProps;
7
+ export declare const InputCheckbox: FC<IInputCheckbox>;
8
+ export {};
@@ -0,0 +1 @@
1
+ export * from './multi-choice-list';
@@ -0,0 +1 @@
1
+ export * from './multi-choice-list';
@@ -0,0 +1,11 @@
1
+ import { FC } from '@helpers';
2
+ import { IInputCheckbox } from '../../molecules/input-checkbox';
3
+ interface IOption extends IInputCheckbox {
4
+ id: string;
5
+ helpfulMessage?: string;
6
+ }
7
+ interface IMultiChoiceList {
8
+ options: IOption[];
9
+ }
10
+ export declare const MultiChoiceList: FC<IMultiChoiceList>;
11
+ export {};
@@ -0,0 +1 @@
1
+ export * from './spinner';
@@ -0,0 +1,10 @@
1
+ import { MappedEnum, RequireOnlyOne, PropsWithChildren } from '@helpers';
2
+ declare const enum SpinnerSize {
3
+ small = 1,
4
+ medium = 2,
5
+ large = 4
6
+ }
7
+ declare type SpinnerSizes<T> = MappedEnum<typeof SpinnerSize, T>;
8
+ export declare type SpinnerProps = Partial<RequireOnlyOne<SpinnerSizes<boolean>>> & PropsWithChildren;
9
+ export declare function getValuesBySize(props: SpinnerProps): string;
10
+ export {};
@@ -0,0 +1,9 @@
1
+ import { SpinnerProps } from './spinner-size-flags';
2
+ import { FC } from '@helpers';
3
+ declare type IProps = SpinnerProps & {
4
+ onPrimary?: boolean;
5
+ onCritical?: boolean;
6
+ className?: string;
7
+ };
8
+ export declare const Spinner: FC<IProps>;
9
+ export {};
@@ -0,0 +1 @@
1
+ export * from './thumbnail';
@@ -0,0 +1,10 @@
1
+ import { MappedEnum, RequireOnlyOne, PropsWithChildren } from '@helpers';
2
+ declare const enum ThumbnailSize {
3
+ small = 1,
4
+ medium = 2,
5
+ large = 4
6
+ }
7
+ declare type ThumbnailSizes<T> = MappedEnum<typeof ThumbnailSize, T>;
8
+ export declare type ThumbnailSizeProps = Partial<RequireOnlyOne<ThumbnailSizes<boolean>>> & PropsWithChildren;
9
+ export declare function getValuesBySize(props: ThumbnailSizeProps): string;
10
+ export {};
@@ -0,0 +1,9 @@
1
+ import { FC } from '@helpers';
2
+ import { ThumbnailSizeProps } from './thumbnail-size-flags';
3
+ interface IThumbnailProps {
4
+ imageUrl?: string;
5
+ imageLabel?: string;
6
+ }
7
+ declare type IProps = IThumbnailProps & ThumbnailSizeProps;
8
+ export declare const Thumbnail: FC<IProps>;
9
+ export {};