@veeqo/ui 0.0.3 → 0.0.4

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 (43) hide show
  1. package/CHANGELOG.md +9 -1
  2. package/lib/components/ActionList/styled.d.ts +24 -3
  3. package/lib/components/Button/Button.d.ts +8 -2
  4. package/lib/components/Button/types.d.ts +2 -2
  5. package/lib/components/DimensionsInput/styled.d.ts +8 -1
  6. package/lib/components/PageHeader/styled.d.ts +8 -1
  7. package/lib/components/Pagination/styled.d.ts +8 -1
  8. package/lib/components/VideoModal/styled.d.ts +8 -1
  9. package/lib/components/WeightInput/styled.d.ts +8 -1
  10. package/lib/index.d.ts +5 -1702
  11. package/lib/index.esm.js.map +1 -1
  12. package/lib/index.js.map +1 -1
  13. package/package.json +1 -1
  14. package/rollup.config.mjs +6 -19
  15. package/src/components/Button/types.ts +2 -2
  16. package/tsconfig.json +1 -1
  17. package/lib/components/Button/components/DropdownIcon.d.ts +0 -2
  18. package/lib/components/CardHeader/icons/Cross.d.ts +0 -2
  19. package/lib/components/CardHeader/icons/DownArrow.d.ts +0 -2
  20. package/lib/components/CardHeader/icons/UpArrow.d.ts +0 -2
  21. package/lib/components/Choice/components/HelpIcon.d.ts +0 -2
  22. package/lib/components/DataTable/icons/DoubleArrowAsc.d.ts +0 -2
  23. package/lib/components/DataTable/icons/DoubleArrowDesc.d.ts +0 -2
  24. package/lib/components/DataTable/icons/DoubleArrowIcon.d.ts +0 -2
  25. package/lib/components/DataTableExp/components/icons/ArrowDown.d.ts +0 -2
  26. package/lib/components/DataTableExp/components/icons/ArrowUp.d.ts +0 -2
  27. package/lib/components/DataTableExp/components/icons/DoubleArrow.d.ts +0 -2
  28. package/lib/components/DataTableExp/components/icons/InfoIcon.d.ts +0 -2
  29. package/lib/components/DataTableExp/components/icons/Reorder.d.ts +0 -2
  30. package/lib/components/DataTableExp/components/icons/Visibility.d.ts +0 -2
  31. package/lib/components/DataTableExp/components/icons/VisibilityOff.d.ts +0 -2
  32. package/lib/components/Pagination/components/EndArrow.d.ts +0 -2
  33. package/lib/components/Pagination/components/LeftArrow.d.ts +0 -2
  34. package/lib/components/Pagination/components/RightArrow.d.ts +0 -2
  35. package/lib/components/Pagination/components/StartArrow.d.ts +0 -2
  36. package/lib/hoc/withLabels/HelpIcon.d.ts +0 -2
  37. package/lib/theme/utils/buildClassnames.d.ts +0 -1
  38. package/lib/theme/utils/color.d.ts +0 -13
  39. package/lib/theme/utils/generateId.d.ts +0 -1
  40. package/lib/theme/utils/index.d.ts +0 -3
  41. package/lib/theme/utils/paginationList.d.ts +0 -4
  42. package/lib/theme/utils/setupIntersectionObserverMock.d.ts +0 -18
  43. package/lib/utils/toMap.d.ts +0 -5
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@veeqo/ui",
3
- "version": "0.0.3",
3
+ "version": "0.0.4",
4
4
  "description": "New optimised component library for Veeqo.",
5
5
  "author": "Robert Wealthall",
6
6
  "license": "UNLICENSED",
package/rollup.config.mjs CHANGED
@@ -1,4 +1,3 @@
1
- import typescriptEngine from 'typescript';
2
1
  import dts from 'rollup-plugin-dts';
3
2
  import terser from '@rollup/plugin-terser';
4
3
  import peerDepsExternal from 'rollup-plugin-peer-deps-external';
@@ -9,7 +8,7 @@ import packageJson from './package.json' assert { type: 'json' };
9
8
 
10
9
  export default [
11
10
  {
12
- input: 'src/index.ts',
11
+ input: './src/index.ts',
13
12
  output: [
14
13
  {
15
14
  file: packageJson.main,
@@ -19,31 +18,19 @@ export default [
19
18
  {
20
19
  file: packageJson.module,
21
20
  format: 'esm',
21
+ exports: 'named',
22
22
  sourcemap: true,
23
23
  },
24
24
  ],
25
25
  plugins: [
26
- peerDepsExternal(), // Don't include peer dependencies, should be given by client.
27
- resolve(), // Resolve paths
28
26
  typescript({
29
27
  tsconfig: './tsconfig.json',
30
- typescript: typescriptEngine,
31
- sourceMap: true,
32
- exclude: [
33
- '**/__snapshots__/*',
34
- '**/__tests__',
35
- '**/*.test.ts+(|x)',
36
- '**/*.story.ts+(|x)',
37
- '**/*.stories.ts+(|x)',
38
- '**/*.mdx',
39
- ],
28
+ sourceMap: false,
29
+ exclude: ['**/__snapshots__/*', '**/*.test.ts+(|x)', '**/*.stories.ts+(|x)', '**/*.mdx'],
40
30
  }),
31
+ peerDepsExternal(), // Don't include peer dependencies, should be given by client.
32
+ resolve(), // Resolve paths
41
33
  terser(),
42
34
  ],
43
35
  },
44
- {
45
- input: 'lib/index.d.ts',
46
- output: [{ file: 'lib/index.d.ts', format: 'esm' }],
47
- plugins: [dts()],
48
- },
49
36
  ];
@@ -12,7 +12,7 @@ export type ButtonVariant =
12
12
  /**
13
13
  * Button properties.
14
14
  */
15
- export interface ButtonProps extends ButtonHTMLAttributes<HTMLButtonElement> {
15
+ export type ButtonProps = ButtonHTMLAttributes<HTMLButtonElement> & {
16
16
  children?: ReactNode;
17
17
  /** Variant styles */
18
18
  variant?: ButtonVariant;
@@ -24,4 +24,4 @@ export interface ButtonProps extends ButtonHTMLAttributes<HTMLButtonElement> {
24
24
  dropdown?: boolean;
25
25
  /** Renders a loading indicator inside the button */
26
26
  loading?: boolean;
27
- }
27
+ };
package/tsconfig.json CHANGED
@@ -11,7 +11,7 @@
11
11
  "lib": ["dom", "dom.iterable", "esnext"],
12
12
  "module": "esnext",
13
13
  "moduleResolution": "Node",
14
- "noEmit": true,
14
+ "noEmit": false,
15
15
  "outDir": "lib",
16
16
  "resolveJsonModule": true,
17
17
  "skipLibCheck": true,
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const DropdownIcon: () => React.JSX.Element;
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const Cross: (props: any) => React.JSX.Element;
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const DownArrow: (props: any) => React.JSX.Element;
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const UpArrow: (props: any) => React.JSX.Element;
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const HelpIcon: (props: any) => React.JSX.Element;
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const DoubleArrowAscIcon: (props: any) => React.JSX.Element;
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const DoubleArrowDescIcon: (props: any) => React.JSX.Element;
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const DoubleArrowIcon: (props: any) => React.JSX.Element;
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const ArrowDown: (props: any) => React.JSX.Element;
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const ArrowUp: (props: any) => React.JSX.Element;
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const DoubleArrow: (props: any) => React.JSX.Element;
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const InfoIcon: (props: any) => React.JSX.Element;
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const Reorder: (props: any) => React.JSX.Element;
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const Visiblity: (props: any) => React.JSX.Element;
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const VisiblityOff: (props: any) => React.JSX.Element;
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const EndArrow: (props: any) => React.JSX.Element;
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const LeftArrow: (props: any) => React.JSX.Element;
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const RightArrow: (props: any) => React.JSX.Element;
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const StartArrow: (props: any) => React.JSX.Element;
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const HelpIcon: (props: any) => React.JSX.Element;
@@ -1 +0,0 @@
1
- export declare const buildClassnames: (names: (string | undefined)[]) => string;
@@ -1,13 +0,0 @@
1
- /**
2
- * A function to convert hex color to rgb.
3
- */
4
- export declare const hexToRgb: (hex: string) => {
5
- r: number;
6
- g: number;
7
- b: number;
8
- } | null;
9
- /**
10
- * A function to get a hex color with opacity, after converting to `rgba`.
11
- * @param hex color in hex format
12
- */
13
- export declare const getOpaqueHexColor: (hex: string, opacity: number) => string;
@@ -1 +0,0 @@
1
- export declare const generateId: (prefix: string) => string;
@@ -1,3 +0,0 @@
1
- export { buildClassnames } from './buildClassnames';
2
- export { getOpaqueHexColor, hexToRgb } from './color';
3
- export { generateId } from './generateId';
@@ -1,4 +0,0 @@
1
- export declare const paginationDefaultRangeList: {
2
- label: string;
3
- value: number;
4
- }[];
@@ -1,18 +0,0 @@
1
- /**
2
- * https://stackoverflow.com/a/58651649
3
- *
4
- * Utility function that mocks the `IntersectionObserver` API. Necessary for components that rely
5
- * on it, otherwise the tests will crash. Recommended to execute inside `beforeEach`.
6
- * @param intersectionObserverMock - Parameter that is sent to the `Object.defineProperty`
7
- * overwrite method. `jest.fn()` mock functions can be passed here if the goal is to not only
8
- * mock the intersection observer, but its methods.
9
- */
10
- export declare function setupIntersectionObserverMock({ root, rootMargin, thresholds, disconnect, observe, takeRecords, unobserve, }?: {
11
- root?: null | undefined;
12
- rootMargin?: string | undefined;
13
- thresholds?: never[] | undefined;
14
- disconnect?: (() => null) | undefined;
15
- observe?: (() => null) | undefined;
16
- takeRecords?: (() => never[]) | undefined;
17
- unobserve?: (() => null) | undefined;
18
- }): void;
@@ -1,5 +0,0 @@
1
- type MapType = {
2
- [key: string]: string;
3
- };
4
- export declare const toMap: (arr: string[]) => MapType;
5
- export {};