@itilite/lumina-ui 0.0.3 → 0.0.5

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 (33) hide show
  1. package/dist/cjs/index.css +1 -1
  2. package/dist/cjs/index.js +22751 -8
  3. package/dist/cjs/index.js.map +1 -1
  4. package/dist/cjs/types/components/Button/types.d.ts +2 -0
  5. package/dist/esm/index.css +1 -1
  6. package/dist/esm/index.js +22728 -3
  7. package/dist/esm/index.js.map +1 -1
  8. package/dist/esm/types/components/Button/types.d.ts +2 -0
  9. package/package.json +89 -88
  10. package/src/components/Button/Button.module.scss +8 -2
  11. package/src/components/Button/Button.tsx +4 -0
  12. package/src/components/Button/types.ts +2 -0
  13. package/dist/types/components/Button/Button.d.ts +0 -4
  14. package/dist/types/components/Button/Button.test.d.ts +0 -1
  15. package/dist/types/components/Button/index.d.ts +0 -1
  16. package/dist/types/components/Button/types.d.ts +0 -16
  17. package/dist/types/components/Checkbox/Checkbox.d.ts +0 -4
  18. package/dist/types/components/Checkbox/index.d.ts +0 -1
  19. package/dist/types/components/Checkbox/types.d.ts +0 -11
  20. package/dist/types/components/Modal/Modal.d.ts +0 -3
  21. package/dist/types/components/Modal/index.d.ts +0 -1
  22. package/dist/types/components/Modal/types.d.ts +0 -21
  23. package/dist/types/components/Radio/Radio.d.ts +0 -4
  24. package/dist/types/components/Radio/index.d.ts +0 -1
  25. package/dist/types/components/Radio/types.d.ts +0 -11
  26. package/dist/types/components/Switch/Switch.d.ts +0 -4
  27. package/dist/types/components/Switch/index.d.ts +0 -1
  28. package/dist/types/components/Switch/types.d.ts +0 -7
  29. package/dist/types/components/Tooltip/Tooltip.d.ts +0 -3
  30. package/dist/types/components/Tooltip/index.d.ts +0 -1
  31. package/dist/types/components/Tooltip/types.d.ts +0 -8
  32. package/dist/types/components/index.d.ts +0 -6
  33. package/dist/types/index.d.ts +0 -1
@@ -1,4 +1,6 @@
1
1
  export interface ButtonProps {
2
+ id?: string;
3
+ name?: string;
2
4
  type?: "primary" | "secondary" | "critical" | undefined;
3
5
  variant?: "subtle" | "text" | "link";
4
6
  size?: "large" | "small";
package/package.json CHANGED
@@ -1,89 +1,90 @@
1
1
  {
2
- "name": "@itilite/lumina-ui",
3
- "version": "0.0.3",
4
- "description": "Design system",
5
- "main": "dist/cjs/index.js",
6
- "module": "dist/esm/index.js",
7
- "types": "dist/types/index.d.ts",
8
- "scripts": {
9
- "build:types": "tsc --emitDeclarationOnly",
10
- "build": "rollup -c",
11
- "build:all": "rollup -c && tsc --emitDeclarationOnly",
12
- "dev": "rollup -c -w",
13
- "lint": "eslint ",
14
- "lint:fix": "eslint ./src --ext .ts,.tsx --fix",
15
- "test": "jest",
16
- "publish": "npm init --scope=itilite && npm publish"
17
- },
18
- "author": "Itilite",
19
- "license": "ISC",
20
- "devDependencies": {
21
- "@babel/core": "^7.25.9",
22
- "@babel/preset-env": "^7.25.9",
23
- "@babel/preset-react": "^7.25.9",
24
- "@babel/preset-typescript": "^7.25.9",
25
- "@rollup/plugin-commonjs": "^26.0.1",
26
- "@rollup/plugin-node-resolve": "^15.2.3",
27
- "@rollup/plugin-typescript": "^11.1.6",
28
- "@testing-library/jest-dom": "^6.6.2",
29
- "@testing-library/react": "^16.0.1",
30
- "@types/jest": "^29.5.12",
31
- "@types/prop-types": "^15.7.12",
32
- "@types/react": "^18.3.12",
33
- "@types/react-dom": "^18.3.0",
34
- "@typescript-eslint/eslint-plugin": "^8.2.0",
35
- "@typescript-eslint/parser": "^8.2.0",
36
- "antd": "^5.20.1",
37
- "autoprefixer": "^10.4.20",
38
- "babel-jest": "^29.7.0",
39
- "clsx": "^2.1.1",
40
- "eslint": "^9.9.0",
41
- "eslint-config-standard-with-typescript": "^43.0.1",
42
- "eslint-define-config": "^2.1.0",
43
- "eslint-plugin-import": "^2.29.1",
44
- "eslint-plugin-react": "^7.35.0",
45
- "eslint-plugin-react-hooks": "^5.1.0-rc.0",
46
- "eslint-plugin-simple-import-sort": "^12.1.1",
47
- "eslint-plugin-unused-imports": "^4.1.3",
48
- "identity-obj-proxy": "^3.0.0",
49
- "jest": "^29.7.0",
50
- "jest-environment-jsdom": "^29.7.0",
51
- "postcss": "^8.4.41",
52
- "postcss-scss": "^4.0.9",
53
- "prop-types": "^15.8.1",
54
- "react": "^18.3.1",
55
- "react-dom": "^18.3.1",
56
- "rollup": "^4.21.0",
57
- "rollup-plugin-dts": "^6.1.1",
58
- "rollup-plugin-peer-deps-external": "^2.2.4",
59
- "rollup-plugin-postcss": "^4.0.2",
60
- "rollup-plugin-scss": "^4.0.0",
61
- "sass": "^1.77.8",
62
- "tailwindcss": "^3.4.10",
63
- "tslib": "^2.6.3",
64
- "typescript": "^5.5.3"
65
- },
66
- "peerDependencies": {
67
- "react": ">=18"
68
- },
69
- "jest": {
70
- "setupFilesAfterEnv": [
71
- "<rootDir>/src/setupTests.ts"
72
- ],
73
- "testEnvironment": "jsdom"
74
- },
75
- "repository": {
76
- "type": "git",
77
- "url": "git+https://github.com/Itilite/design-system.git"
78
- },
79
- "keywords": [
80
- "Design",
81
- "system",
82
- "LuminaUI",
83
- "Frontend"
84
- ],
85
- "bugs": {
86
- "url": "https://github.com/Itilite/design-system/issues"
87
- },
88
- "homepage": "https://github.com/Itilite/design-system#readme"
89
- }
2
+ "name": "@itilite/lumina-ui",
3
+ "version": "0.0.5",
4
+ "description": "Design system",
5
+ "main": "dist/cjs/index.js",
6
+ "module": "dist/esm/index.js",
7
+ "types": "dist/types/index.d.ts",
8
+ "author": "Itilite",
9
+ "license": "ISC",
10
+ "devDependencies": {
11
+ "@babel/core": "^7.25.9",
12
+ "@babel/preset-env": "^7.25.9",
13
+ "@babel/preset-react": "^7.25.9",
14
+ "@babel/preset-typescript": "^7.25.9",
15
+ "@rollup/plugin-commonjs": "^26.0.1",
16
+ "@rollup/plugin-node-resolve": "^15.2.3",
17
+ "@rollup/plugin-typescript": "^11.1.6",
18
+ "@testing-library/jest-dom": "^6.6.2",
19
+ "@testing-library/react": "^16.0.1",
20
+ "@types/jest": "^29.5.12",
21
+ "@types/prop-types": "^15.7.12",
22
+ "@types/react": "^18.3.12",
23
+ "@types/react-dom": "^18.3.0",
24
+ "@typescript-eslint/eslint-plugin": "^8.2.0",
25
+ "@typescript-eslint/parser": "^8.2.0",
26
+ "antd": "^5.20.1",
27
+ "autoprefixer": "^10.4.20",
28
+ "babel-jest": "^29.7.0",
29
+ "clsx": "^2.1.1",
30
+ "eslint": "^9.9.0",
31
+ "eslint-config-standard-with-typescript": "^43.0.1",
32
+ "eslint-define-config": "^2.1.0",
33
+ "eslint-plugin-import": "^2.29.1",
34
+ "eslint-plugin-react": "^7.35.0",
35
+ "eslint-plugin-react-hooks": "^5.1.0-rc.0",
36
+ "eslint-plugin-simple-import-sort": "^12.1.1",
37
+ "eslint-plugin-unused-imports": "^4.1.3",
38
+ "glob": "9.3.5",
39
+ "identity-obj-proxy": "^3.0.0",
40
+ "jest": "^29.7.0",
41
+ "jest-environment-jsdom": "^29.7.0",
42
+ "postcss": "^8.4.41",
43
+ "postcss-scss": "^4.0.9",
44
+ "prop-types": "^15.8.1",
45
+ "react": "^18.3.1",
46
+ "react-dom": "^18.3.1",
47
+ "rollup": "^4.21.0",
48
+ "rollup-plugin-dts": "^6.1.1",
49
+ "rollup-plugin-peer-deps-external": "^2.2.4",
50
+ "rollup-plugin-postcss": "^4.0.2",
51
+ "rollup-plugin-scss": "^4.0.0",
52
+ "sass": "^1.77.8",
53
+ "tailwindcss": "^3.4.10",
54
+ "tslib": "^2.6.3",
55
+ "typescript": "^5.5.3"
56
+ },
57
+ "peerDependencies": {
58
+ "react": ">=18"
59
+ },
60
+ "jest": {
61
+ "setupFilesAfterEnv": [
62
+ "<rootDir>/src/setupTests.ts"
63
+ ],
64
+ "testEnvironment": "jsdom"
65
+ },
66
+ "repository": {
67
+ "type": "git",
68
+ "url": "git+https://github.com/Itilite/design-system.git"
69
+ },
70
+ "keywords": [
71
+ "Design",
72
+ "system",
73
+ "LuminaUI",
74
+ "Frontend"
75
+ ],
76
+ "bugs": {
77
+ "url": "https://github.com/Itilite/design-system/issues"
78
+ },
79
+ "homepage": "https://github.com/Itilite/design-system#readme",
80
+ "scripts": {
81
+ "build:types": "tsc --emitDeclarationOnly",
82
+ "build": "rollup -c",
83
+ "prebuild:all": "node -v && npm -v && pwd && ls -la",
84
+ "build:all": "ROLLUP_DEBUG=* rollup -c && tsc --emitDeclarationOnly",
85
+ "dev": "rollup -c -w",
86
+ "lint": "eslint ",
87
+ "lint:fix": "eslint ./src --ext .ts,.tsx --fix",
88
+ "test": "jest"
89
+ }
90
+ }
@@ -35,13 +35,19 @@
35
35
  @apply tw-bg-color-action-primary;
36
36
  box-shadow: 0px 2px 4px 0px rgba(17, 24, 39, 0.1);
37
37
  }
38
+ &.variant_subtle {
39
+ @apply tw-text-color-text-primary;
40
+ &:hover {
41
+ @apply tw-text-color-text-primary-hover;
42
+ }
43
+ }
38
44
  &:focus-visible {
39
45
  outline: 2px solid #ec5d2561;
40
46
  }
41
47
  &.variant_subtle {
42
48
  @apply tw-text-color-text-primary;
43
49
  &:hover {
44
- @apply tw-text-color-text-primary;
50
+ @apply tw-text-color-text-primary-hover;
45
51
  }
46
52
  }
47
53
  &.variant_text,
@@ -147,7 +153,7 @@
147
153
  @apply tw-h-auto;
148
154
  box-shadow: none;
149
155
  &:global(.ant-btn-default):hover {
150
- &.onHoverUnderline{
156
+ &.onHoverUnderline {
151
157
  text-decoration: underline;
152
158
  }
153
159
  box-shadow: none;
@@ -21,6 +21,8 @@ const Button: React.FC<ButtonProps> = (props) => {
21
21
  disabled = false,
22
22
  loading = false,
23
23
  onHoverUnderline = false,
24
+ id = "",
25
+ name = ""
24
26
  } = props;
25
27
 
26
28
  const buttonMap: Record<string, "primary" | "default" | "text" | "link"> = {
@@ -38,6 +40,8 @@ const Button: React.FC<ButtonProps> = (props) => {
38
40
 
39
41
  return (
40
42
  <AntButton
43
+ id={id}
44
+ name={name}
41
45
  className={clsx(
42
46
  classes.button,
43
47
  classes[`size_${size}`],
@@ -1,4 +1,6 @@
1
1
  export interface ButtonProps {
2
+ id?: string;
3
+ name?: string;
2
4
  type?: "primary" | "secondary" | "critical" | undefined;
3
5
  variant?: "subtle" | "text" | "link";
4
6
  size?: "large" | "small";
@@ -1,4 +0,0 @@
1
- import * as React from "react";
2
- import { ButtonProps } from "./types";
3
- declare const Button: React.FC<ButtonProps>;
4
- export default Button;
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export { default as Button } from "./Button";
@@ -1,16 +0,0 @@
1
- export interface ButtonProps {
2
- type?: "primary" | "secondary" | "critical" | undefined;
3
- variant?: "subtle" | "text" | "link";
4
- size?: "large" | "small";
5
- shape?: "circle" | "default" | "round";
6
- icon?: React.ReactNode;
7
- iconPosition?: "start" | "end";
8
- className?: string;
9
- children?: React.ReactNode;
10
- onClick?: (event: React.MouseEvent<HTMLElement>) => void;
11
- href?: string;
12
- disabled?: boolean;
13
- loading?: boolean;
14
- onHoverUnderline?: boolean;
15
- analytics?: Record<string, unknown>;
16
- }
@@ -1,4 +0,0 @@
1
- import * as React from "react";
2
- import { CheckboxProps } from "./types";
3
- declare const Checkbox: React.FC<CheckboxProps>;
4
- export default Checkbox;
@@ -1 +0,0 @@
1
- export { default as Checkbox } from "./Checkbox";
@@ -1,11 +0,0 @@
1
- import { CheckboxChangeEvent } from 'antd/es/checkbox';
2
- export interface CheckboxProps {
3
- checked?: boolean;
4
- className?: string;
5
- onChange?: (e: CheckboxChangeEvent) => void;
6
- children?: React.ReactNode;
7
- size?: "large" | "small" | "medium";
8
- variant?: "normal" | "emphasized";
9
- disabled?: boolean;
10
- indeterminate?: boolean;
11
- }
@@ -1,3 +0,0 @@
1
- import { ModalProps } from "./types";
2
- declare const Modal: React.FC<ModalProps>;
3
- export default Modal;
@@ -1 +0,0 @@
1
- export { default as Modal } from "./Modal";
@@ -1,21 +0,0 @@
1
- export interface ModalProps {
2
- className?: string | undefined;
3
- title?: string | undefined;
4
- children?: React.ReactNode;
5
- open?: boolean;
6
- handleOk?: ((e: React.MouseEvent<HTMLButtonElement>) => void) | undefined;
7
- handleCancel?: ((e: React.MouseEvent<HTMLButtonElement>) => void) | undefined;
8
- okText?: string | undefined;
9
- cancelText?: string | undefined;
10
- closeIcon?: React.ReactNode;
11
- bodyClassName?: string | undefined;
12
- outsideClickDisable?: boolean;
13
- hideCross?: boolean;
14
- okButtonLoading?: boolean;
15
- okButtonDisabled?: boolean;
16
- variant?: "primary" | "secondary";
17
- okBtnClasses?: string | undefined;
18
- cancelButtonAnalytics?: object | undefined;
19
- okButtonAnalytics?: object | undefined;
20
- footerMargintopDisable?: boolean;
21
- }
@@ -1,4 +0,0 @@
1
- import React from "react";
2
- import { RadioProps } from "./types";
3
- declare const Radio: React.FC<RadioProps>;
4
- export default Radio;
@@ -1 +0,0 @@
1
- export { default as Radio } from "./Radio";
@@ -1,11 +0,0 @@
1
- import { RadioChangeEvent } from "antd/lib/radio";
2
- export interface RadioProps {
3
- checked?: boolean;
4
- className?: string;
5
- onChange?: (event: RadioChangeEvent) => void;
6
- children?: React.ReactNode;
7
- size?: "large" | "small" | "medium";
8
- variant?: "normal" | "emphasized";
9
- disabled?: boolean;
10
- extra?: React.ReactNode;
11
- }
@@ -1,4 +0,0 @@
1
- import * as React from "react";
2
- import { SwitchProps } from "./types";
3
- declare const Switch: React.FC<SwitchProps>;
4
- export default Switch;
@@ -1 +0,0 @@
1
- export { default as Switch } from "./Switch";
@@ -1,7 +0,0 @@
1
- export interface SwitchProps {
2
- size?: "default" | "small";
3
- className?: string | undefined;
4
- onChange?: (checked: boolean, event: React.MouseEvent<HTMLButtonElement> | React.KeyboardEvent<HTMLButtonElement>) => void;
5
- disabled?: boolean;
6
- checked?: boolean;
7
- }
@@ -1,3 +0,0 @@
1
- import { TooltipProps } from "./types";
2
- declare const Tooltip: React.FC<TooltipProps>;
3
- export default Tooltip;
@@ -1 +0,0 @@
1
- export { default as Tooltip } from "./Tooltip";
@@ -1,8 +0,0 @@
1
- export interface TooltipProps {
2
- children?: React.ReactNode;
3
- title?: string | undefined;
4
- placement?: "top" | "left" | "right" | "bottom" | "topLeft" | "topRight" | "bottomLeft" | "bottomRight" | "leftTop" | "leftBottom" | "rightTop" | "rightBottom" | undefined;
5
- color?: string | undefined;
6
- className?: string | undefined;
7
- mode?: "light" | "dark";
8
- }
@@ -1,6 +0,0 @@
1
- export * from "./Button";
2
- export * from "./Switch";
3
- export * from "./Modal";
4
- export * from "./Tooltip";
5
- export * from './Checkbox';
6
- export * from './Radio';
@@ -1 +0,0 @@
1
- export * from "./components";