@covalent/components-react 0.0.0-COVALENT

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 (122) hide show
  1. package/.eslintrc.json +23 -0
  2. package/README.md +168 -0
  3. package/package.json +10 -0
  4. package/project.json +48 -0
  5. package/src/ActionRibbon/CovalentActionRibbon.spec.ts +7 -0
  6. package/src/ActionRibbon/CovalentActionRibbon.tsx +8 -0
  7. package/src/Alert/CovalentAlert.spec.ts +7 -0
  8. package/src/Alert/CovalentAlert.tsx +8 -0
  9. package/src/AppShell/CovalentAppShell.spec.ts +7 -0
  10. package/src/AppShell/CovalentAppShell.tsx +11 -0
  11. package/src/Badge/CovalentBadge.spec.ts +7 -0
  12. package/src/Badge/CovalentBadge.tsx +8 -0
  13. package/src/Button/CovalentButton.spec.ts +7 -0
  14. package/src/Button/CovalentButton.tsx +8 -0
  15. package/src/Card/CovalentCard.spec.ts +7 -0
  16. package/src/Card/CovalentCard.tsx +8 -0
  17. package/src/Checkbox/CovalentCheckbox.spec.ts +7 -0
  18. package/src/Checkbox/CovalentCheckbox.tsx +11 -0
  19. package/src/Chips/CovalentChip.spec.ts +7 -0
  20. package/src/Chips/CovalentChip.tsx +8 -0
  21. package/src/Chips/CovalentChipSet.spec.ts +7 -0
  22. package/src/Chips/CovalentChipSet.tsx +8 -0
  23. package/src/CircularProgress/CovalentCircularProgress.spec.ts +7 -0
  24. package/src/CircularProgress/CovalentCircularProgress.tsx +8 -0
  25. package/src/CodeEditor/CovalentCodeEditor.spec.ts +7 -0
  26. package/src/CodeEditor/CovalentCodeEditor.tsx +14 -0
  27. package/src/CodeSnippet/CovalentCodeSnippet.spec.ts +7 -0
  28. package/src/CodeSnippet/CovalentCodeSnippet.tsx +8 -0
  29. package/src/Dialog/CovalentDialog.spec.ts +7 -0
  30. package/src/Dialog/CovalentDialog.tsx +14 -0
  31. package/src/Drawer/CovalentDrawer.spec.ts +7 -0
  32. package/src/Drawer/CovalentDrawer.tsx +12 -0
  33. package/src/EmptyState/CovalentEmptyState.spec.ts +7 -0
  34. package/src/EmptyState/CovalentEmptyState.tsx +8 -0
  35. package/src/ExpansionPanel/CovalentExpansionPanel.spec.ts +7 -0
  36. package/src/ExpansionPanel/CovalentExpansionPanel.tsx +8 -0
  37. package/src/ExpansionPanel/CovalentExpansionPanelItem.spec.ts +7 -0
  38. package/src/ExpansionPanel/CovalentExpansionPanelItem.tsx +11 -0
  39. package/src/FocusedPage/CovalentFocusedPage.spec.ts +7 -0
  40. package/src/FocusedPage/CovalentFocusedPage.tsx +8 -0
  41. package/src/Formfield/CovalentFormfield.spec.ts +7 -0
  42. package/src/Formfield/CovalentFormfield.tsx +8 -0
  43. package/src/FullScreenDialog/CovalentFullscreenDialog.spec.ts +7 -0
  44. package/src/FullScreenDialog/CovalentFullscreenDialog.tsx +14 -0
  45. package/src/Icon/CovalentIcon.spec.ts +7 -0
  46. package/src/Icon/CovalentIcon.tsx +8 -0
  47. package/src/IconButton/CovalentIconButton.spec.ts +7 -0
  48. package/src/IconButton/CovalentIconButton.tsx +8 -0
  49. package/src/IconButtonToggle/CovalentIconButtonToggle.spec.ts +7 -0
  50. package/src/IconButtonToggle/CovalentIconButtonToggle.tsx +11 -0
  51. package/src/IconCheckbox/CovalentIconCheckToggle.spec.ts +7 -0
  52. package/src/IconCheckbox/CovalentIconCheckToggle.tsx +11 -0
  53. package/src/IconLockup/CovalentIconLockup.spec.ts +7 -0
  54. package/src/IconLockup/CovalentIconLockup.tsx +8 -0
  55. package/src/IconRadio/CovalentIconRadioToggle.spec.ts +7 -0
  56. package/src/IconRadio/CovalentIconRadioToggle.tsx +11 -0
  57. package/src/LinearProgress/CovalentLinearProgress.spec.ts +7 -0
  58. package/src/LinearProgress/CovalentLinearProgress.tsx +8 -0
  59. package/src/List/CovalentCheckListItem.spec.ts +7 -0
  60. package/src/List/CovalentCheckListItem.tsx +11 -0
  61. package/src/List/CovalentList.spec.ts +7 -0
  62. package/src/List/CovalentList.tsx +12 -0
  63. package/src/List/CovalentListItem.spec.ts +7 -0
  64. package/src/List/CovalentListItem.tsx +11 -0
  65. package/src/List/CovalentNavRailListItem.spec.ts +7 -0
  66. package/src/List/CovalentNavRailListItem.tsx +11 -0
  67. package/src/List/CovalentRadioListItem.spec.ts +7 -0
  68. package/src/List/CovalentRadioListItem.tsx +11 -0
  69. package/src/Menu/CovalentMenu.spec.ts +7 -0
  70. package/src/Menu/CovalentMenu.tsx +15 -0
  71. package/src/NotebookCell/CovalentNotebookCell.spec.ts +7 -0
  72. package/src/NotebookCell/CovalentNotebookCell.tsx +8 -0
  73. package/src/Radio/CovalentRadio.spec.ts +7 -0
  74. package/src/Radio/CovalentRadio.tsx +11 -0
  75. package/src/Select/CovalentSelect.spec.ts +7 -0
  76. package/src/Select/CovalentSelect.tsx +13 -0
  77. package/src/SideSheet/CovalentSideSheet.spec.ts +7 -0
  78. package/src/SideSheet/CovalentSideSheet.tsx +14 -0
  79. package/src/Slider/CovalentSlider.spec.ts +7 -0
  80. package/src/Slider/CovalentSlider.tsx +12 -0
  81. package/src/Slider/CovalentSliderRange.spec.ts +7 -0
  82. package/src/Slider/CovalentSliderRange.tsx +12 -0
  83. package/src/Snackbar/CovalentSnackbar.spec.ts +7 -0
  84. package/src/Snackbar/CovalentSnackbar.tsx +14 -0
  85. package/src/StatusDialog/CovalentStatusDialog.spec.ts +7 -0
  86. package/src/StatusDialog/CovalentStatusDialog.tsx +14 -0
  87. package/src/StatusHeader/CovalentStatusHeader.spec.ts +7 -0
  88. package/src/StatusHeader/CovalentStatusHeader.tsx +8 -0
  89. package/src/StatusHeader/CovalentStatusHeaderItem.spec.ts +7 -0
  90. package/src/StatusHeader/CovalentStatusHeaderItem.tsx +8 -0
  91. package/src/Switch/CovalentSwitch.spec.ts +7 -0
  92. package/src/Switch/CovalentSwitch.tsx +8 -0
  93. package/src/Tab/CovalentTab.spec.ts +7 -0
  94. package/src/Tab/CovalentTab.tsx +11 -0
  95. package/src/Tab/CovalentTabBar.spec.ts +7 -0
  96. package/src/Tab/CovalentTabBar.tsx +11 -0
  97. package/src/TextLockup/CovalentTextLockup.spec.ts +7 -0
  98. package/src/TextLockup/CovalentTextLockup.tsx +8 -0
  99. package/src/Textarea/CovalentTextArea.spec.ts +7 -0
  100. package/src/Textarea/CovalentTextArea.tsx +8 -0
  101. package/src/Textfield/CovalentTextField.spec.ts +7 -0
  102. package/src/Textfield/CovalentTextField.tsx +8 -0
  103. package/src/Toolbar/CovalentToolbar.spec.ts +7 -0
  104. package/src/Toolbar/CovalentToolbar.tsx +11 -0
  105. package/src/Tooltip/CovalentTooltip.spec.ts +7 -0
  106. package/src/Tooltip/CovalentTooltip.tsx +8 -0
  107. package/src/TopAppBar/CovalentTopAppBar.spec.ts +7 -0
  108. package/src/TopAppBar/CovalentTopAppBar.tsx +11 -0
  109. package/src/TopAppBar/CovalentTopAppBarFixed.spec.ts +7 -0
  110. package/src/TopAppBar/CovalentTopAppBarFixed.tsx +11 -0
  111. package/src/TreeList/CovalentTreeList.spec.ts +7 -0
  112. package/src/TreeList/CovalentTreeList.tsx +11 -0
  113. package/src/TreeList/CovalentTreeListItem.spec.ts +7 -0
  114. package/src/TreeList/CovalentTreeListItem.tsx +11 -0
  115. package/src/Typography/CovalentTypography.spec.ts +7 -0
  116. package/src/Typography/CovalentTypography.tsx +11 -0
  117. package/src/index.ts +56 -0
  118. package/tsconfig.json +24 -0
  119. package/tsconfig.lib.json +10 -0
  120. package/tsconfig.spec.json +21 -0
  121. package/types.d.ts +14 -0
  122. package/vite.config.ts +66 -0
@@ -0,0 +1,7 @@
1
+ import { CovalentTooltip } from './CovalentTooltip';
2
+
3
+ describe('CovalentTooltip', () => {
4
+ it('should work', () => {
5
+ expect(CovalentTooltip).toBeTruthy();
6
+ });
7
+ });
@@ -0,0 +1,8 @@
1
+ import * as React from 'react';
2
+ import { createComponent } from '@lit/react';
3
+ import { CovalentTooltip as CovalentTooltipWeb } from '@covalent/components';
4
+ export const CovalentTooltip = createComponent({
5
+ tagName: 'cv-tooltip',
6
+ elementClass: CovalentTooltipWeb,
7
+ react: React,
8
+ });
@@ -0,0 +1,7 @@
1
+ import { CovalentTopAppBar } from './CovalentTopAppBar';
2
+
3
+ describe('CovalentTopAppBar', () => {
4
+ it('should work', () => {
5
+ expect(CovalentTopAppBar).toBeTruthy();
6
+ });
7
+ });
@@ -0,0 +1,11 @@
1
+ import * as React from 'react';
2
+ import { createComponent } from '@lit/react';
3
+ import { CovalentTopAppBar as CovalentTopAppBarWeb } from '@covalent/components';
4
+ export const CovalentTopAppBar = createComponent({
5
+ tagName: 'cv-top-app-bar',
6
+ elementClass: CovalentTopAppBarWeb,
7
+ react: React,
8
+ events: {
9
+ onnav: 'nav',
10
+ },
11
+ });
@@ -0,0 +1,7 @@
1
+ import { CovalentTopAppBarFixed } from './CovalentTopAppBarFixed';
2
+
3
+ describe('CovalentTopAppBarFixed', () => {
4
+ it('should work', () => {
5
+ expect(CovalentTopAppBarFixed).toBeTruthy();
6
+ });
7
+ });
@@ -0,0 +1,11 @@
1
+ import * as React from 'react';
2
+ import { createComponent } from '@lit/react';
3
+ import { CovalentTopAppBarFixed as CovalentTopAppBarFixedWeb } from '@covalent/components';
4
+ export const CovalentTopAppBarFixed = createComponent({
5
+ tagName: 'cv-top-app-bar-fixed',
6
+ elementClass: CovalentTopAppBarFixedWeb,
7
+ react: React,
8
+ events: {
9
+ onnav: 'nav',
10
+ },
11
+ });
@@ -0,0 +1,7 @@
1
+ import { CovalentTreeList } from './CovalentTreeList';
2
+
3
+ describe('CovalentTreeList', () => {
4
+ it('should work', () => {
5
+ expect(CovalentTreeList).toBeTruthy();
6
+ });
7
+ });
@@ -0,0 +1,11 @@
1
+ import * as React from 'react';
2
+ import { createComponent } from '@lit/react';
3
+ import { CovalentTreeList as CovalentTreeListWeb } from '@covalent/components';
4
+ export const CovalentTreeList = createComponent({
5
+ tagName: 'cv-tree-list',
6
+ elementClass: CovalentTreeListWeb,
7
+ react: React,
8
+ events: {
9
+ onnav: 'nav',
10
+ },
11
+ });
@@ -0,0 +1,7 @@
1
+ import { CovalentTreeListItem } from './CovalentTreeListItem';
2
+
3
+ describe('CovalentTreeListItem', () => {
4
+ it('should work', () => {
5
+ expect(CovalentTreeListItem).toBeTruthy();
6
+ });
7
+ });
@@ -0,0 +1,11 @@
1
+ import * as React from 'react';
2
+ import { createComponent } from '@lit/react';
3
+ import { CovalentTreeListItem as CovalentTreeListItemWeb } from '@covalent/components';
4
+ export const CovalentTreeListItem = createComponent({
5
+ tagName: 'cv-tree-list-item',
6
+ elementClass: CovalentTreeListItemWeb,
7
+ react: React,
8
+ events: {
9
+ onselect: 'select',
10
+ },
11
+ });
@@ -0,0 +1,7 @@
1
+ import { CovalentTypography } from './CovalentTypography';
2
+
3
+ describe('CovalentTypography', () => {
4
+ it('should work', () => {
5
+ expect(CovalentTypography).toBeTruthy();
6
+ });
7
+ });
@@ -0,0 +1,11 @@
1
+ import * as React from 'react';
2
+ import { createComponent } from '@lit/react';
3
+ import { CovalentTypography as CovalentTypographyWeb } from '@covalent/components';
4
+ export const CovalentTypography = createComponent({
5
+ tagName: 'cv-typography',
6
+ elementClass: CovalentTypographyWeb,
7
+ react: React,
8
+ events: {
9
+ onselect: 'select',
10
+ },
11
+ });
package/src/index.ts ADDED
@@ -0,0 +1,56 @@
1
+ export * from './ActionRibbon/CovalentActionRibbon';
2
+ export * from './Alert/CovalentAlert';
3
+ export * from './AppShell/CovalentAppShell';
4
+ export * from './Badge/CovalentBadge';
5
+ export * from './Button/CovalentButton';
6
+ export * from './Card/CovalentCard';
7
+ export * from './Checkbox/CovalentCheckbox';
8
+ export * from './List/CovalentCheckListItem';
9
+ export * from './Chips/CovalentChip';
10
+ export * from './Chips/CovalentChipSet';
11
+ export * from './CircularProgress/CovalentCircularProgress';
12
+ export * from './CodeEditor/CovalentCodeEditor';
13
+ export * from './CodeSnippet/CovalentCodeSnippet';
14
+ export * from './Dialog/CovalentDialog';
15
+ export * from './Drawer/CovalentDrawer';
16
+ export * from './EmptyState/CovalentEmptyState';
17
+ export * from './ExpansionPanel/CovalentExpansionPanel';
18
+ export * from './ExpansionPanel/CovalentExpansionPanelItem';
19
+ export * from './FocusedPage/CovalentFocusedPage';
20
+ export * from './Formfield/CovalentFormfield';
21
+ export * from './FullScreenDialog/CovalentFullscreenDialog';
22
+ export * from './Icon/CovalentIcon';
23
+ export * from './IconButton/CovalentIconButton';
24
+ export * from './IconButtonToggle/CovalentIconButtonToggle';
25
+ export * from './IconCheckbox/CovalentIconCheckToggle';
26
+ export * from './IconLockup/CovalentIconLockup';
27
+ export * from './IconRadio/CovalentIconRadioToggle';
28
+ export * from './LinearProgress/CovalentLinearProgress';
29
+ export * from './List/CovalentList';
30
+ export * from './List/CovalentListItem';
31
+ export * from './Menu/CovalentMenu';
32
+ export * from './List/CovalentNavRailListItem';
33
+ export * from './NotebookCell/CovalentNotebookCell';
34
+ export * from './Radio/CovalentRadio';
35
+ export * from './List/CovalentRadioListItem';
36
+ export * from './Select/CovalentSelect';
37
+ export * from './SideSheet/CovalentSideSheet';
38
+ export * from './Slider/CovalentSlider';
39
+ export * from './Slider/CovalentSliderRange';
40
+ export * from './Snackbar/CovalentSnackbar';
41
+ export * from './StatusDialog/CovalentStatusDialog';
42
+ export * from './StatusHeader/CovalentStatusHeader';
43
+ export * from './StatusHeader/CovalentStatusHeaderItem';
44
+ export * from './Switch/CovalentSwitch';
45
+ export * from './Tab/CovalentTab';
46
+ export * from './Tab/CovalentTabBar';
47
+ export * from './Textarea/CovalentTextArea';
48
+ export * from './Textfield/CovalentTextField';
49
+ export * from './TextLockup/CovalentTextLockup';
50
+ export * from './Toolbar/CovalentToolbar';
51
+ export * from './Tooltip/CovalentTooltip';
52
+ export * from './TopAppBar/CovalentTopAppBar';
53
+ export * from './TopAppBar/CovalentTopAppBarFixed';
54
+ export * from './TreeList/CovalentTreeList';
55
+ export * from './TreeList/CovalentTreeListItem';
56
+ export * from './Typography/CovalentTypography';
package/tsconfig.json ADDED
@@ -0,0 +1,24 @@
1
+ {
2
+ "extends": "../../tsconfig.base.json",
3
+ "compilerOptions": {
4
+ "module": "commonjs",
5
+ "forceConsistentCasingInFileNames": true,
6
+ "strict": true,
7
+ "noPropertyAccessFromIndexSignature": true,
8
+ "noImplicitReturns": true,
9
+ "noFallthroughCasesInSwitch": true,
10
+ "resolveJsonModule": true,
11
+ "jsx": "react",
12
+ "types": ["vitest", "./types.d.ts"]
13
+ },
14
+ "files": [],
15
+ "include": [],
16
+ "references": [
17
+ {
18
+ "path": "./tsconfig.lib.json"
19
+ },
20
+ {
21
+ "path": "./tsconfig.spec.json"
22
+ }
23
+ ]
24
+ }
@@ -0,0 +1,10 @@
1
+ {
2
+ "extends": "./tsconfig.json",
3
+ "compilerOptions": {
4
+ "outDir": "../../dist/out-tsc",
5
+ "declaration": true,
6
+ "types": ["node"]
7
+ },
8
+ "include": ["src/**/*.ts", "*.d.ts"],
9
+ "exclude": ["jest.config.ts", "src/**/*.spec.ts", "src/**/*.test.ts"]
10
+ }
@@ -0,0 +1,21 @@
1
+ {
2
+ "extends": "./tsconfig.json",
3
+ "compilerOptions": {
4
+ "outDir": "../../dist/out-tsc",
5
+ "types": ["vitest/globals", "vitest/importMeta", "vite/client", "node"],
6
+ "sourceMap": false
7
+ },
8
+ "include": [
9
+ "vite.config.ts",
10
+ "src/**/*.test.ts",
11
+ "src/**/*.spec.ts",
12
+ "src/**/*.test.tsx",
13
+ "src/**/*.spec.tsx",
14
+ "src/**/*.test.js",
15
+ "src/**/*.spec.js",
16
+ "src/**/*.test.jsx",
17
+ "src/**/*.spec.jsx",
18
+ "src/**/*.d.ts",
19
+ "*.d.ts"
20
+ ]
21
+ }
package/types.d.ts ADDED
@@ -0,0 +1,14 @@
1
+ declare module '*.scss' {
2
+ import { CSSResult } from 'lit';
3
+ const css: CSSResult;
4
+ export default css;
5
+ }
6
+ declare module '*.css' {
7
+ import { CSSResult } from 'lit';
8
+ const css: CSSResult;
9
+ export default css;
10
+ }
11
+ declare module '*?inline' {
12
+ const contents: { default: string };
13
+ export = contents;
14
+ }
package/vite.config.ts ADDED
@@ -0,0 +1,66 @@
1
+ /// <reference types='vitest' />
2
+ import { defineConfig } from 'vite';
3
+ import dts from 'vite-plugin-dts';
4
+ import { nxViteTsPaths } from '@nx/vite/plugins/nx-tsconfig-paths.plugin';
5
+ import { nxCopyAssetsPlugin } from '@nx/vite/plugins/nx-copy-assets.plugin';
6
+
7
+ export default defineConfig({
8
+ root: __dirname,
9
+ cacheDir: '../../node_modules/.vite/libs/components-react',
10
+
11
+ plugins: [
12
+ nxViteTsPaths(),
13
+ dts({
14
+ entryRoot: 'src',
15
+ }),
16
+ nxCopyAssetsPlugin(['*.css']),
17
+ ],
18
+
19
+ // Uncomment this if you are using workers.
20
+ // worker: {
21
+ // plugins: [ nxViteTsPaths() ],
22
+ // },
23
+
24
+ // Configuration for building your library.
25
+ // See: https://vitejs.dev/guide/build.html#library-mode
26
+ build: {
27
+ outDir: '../../dist/libs/components-react',
28
+ emptyOutDir: true,
29
+ reportCompressedSize: true,
30
+ commonjsOptions: {
31
+ transformMixedEsModules: true,
32
+ },
33
+ lib: {
34
+ // Could also be a dictionary or array of multiple entry points.
35
+ entry: 'src/index.ts',
36
+ name: 'components-react',
37
+ fileName: 'index',
38
+ // Change this to the formats you want to support.
39
+ // Don't forget to update your package.json as well.
40
+ formats: ['es', 'cjs'],
41
+ },
42
+ rollupOptions: {
43
+ // External packages that should not be bundled into your library.
44
+ external: ['react', '@covalent/components'],
45
+ },
46
+ },
47
+
48
+ test: {
49
+ watch: false,
50
+ globals: true,
51
+ server: {
52
+ deps: {
53
+ inline: [/safevalues/],
54
+ },
55
+ sourcemap: false,
56
+ },
57
+
58
+ environment: 'jsdom',
59
+ include: ['src/**/*.{test,spec}.{js,mjs,cjs,ts,mts,cts,jsx,tsx}'],
60
+ reporters: ['default'],
61
+ coverage: {
62
+ reportsDirectory: '../../coverage/libs/components-react',
63
+ provider: 'v8',
64
+ },
65
+ },
66
+ });