ag-common 0.0.772 → 0.0.774
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.
|
@@ -30,4 +30,5 @@ __exportStar(require("./popover"), exports);
|
|
|
30
30
|
__exportStar(require("./scroll-area"), exports);
|
|
31
31
|
__exportStar(require("./select"), exports);
|
|
32
32
|
__exportStar(require("./sheet"), exports);
|
|
33
|
+
__exportStar(require("./switch"), exports);
|
|
33
34
|
__exportStar(require("./textarea"), exports);
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import * as SwitchPrimitive from '@radix-ui/react-switch';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
interface SwitchProps extends React.ComponentPropsWithoutRef<typeof SwitchPrimitive.Root> {
|
|
4
|
+
icon?: React.ReactNode;
|
|
5
|
+
}
|
|
6
|
+
declare const Switch: React.ForwardRefExoticComponent<SwitchProps & React.RefAttributes<HTMLButtonElement>>;
|
|
7
|
+
export { Switch };
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
'use client';
|
|
3
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
4
|
+
if (k2 === undefined) k2 = k;
|
|
5
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
6
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
7
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
8
|
+
}
|
|
9
|
+
Object.defineProperty(o, k2, desc);
|
|
10
|
+
}) : (function(o, m, k, k2) {
|
|
11
|
+
if (k2 === undefined) k2 = k;
|
|
12
|
+
o[k2] = m[k];
|
|
13
|
+
}));
|
|
14
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
15
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
16
|
+
}) : function(o, v) {
|
|
17
|
+
o["default"] = v;
|
|
18
|
+
});
|
|
19
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
20
|
+
var ownKeys = function(o) {
|
|
21
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
22
|
+
var ar = [];
|
|
23
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
24
|
+
return ar;
|
|
25
|
+
};
|
|
26
|
+
return ownKeys(o);
|
|
27
|
+
};
|
|
28
|
+
return function (mod) {
|
|
29
|
+
if (mod && mod.__esModule) return mod;
|
|
30
|
+
var result = {};
|
|
31
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
32
|
+
__setModuleDefault(result, mod);
|
|
33
|
+
return result;
|
|
34
|
+
};
|
|
35
|
+
})();
|
|
36
|
+
var __rest = (this && this.__rest) || function (s, e) {
|
|
37
|
+
var t = {};
|
|
38
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
39
|
+
t[p] = s[p];
|
|
40
|
+
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
41
|
+
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
42
|
+
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
43
|
+
t[p[i]] = s[p[i]];
|
|
44
|
+
}
|
|
45
|
+
return t;
|
|
46
|
+
};
|
|
47
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
48
|
+
exports.Switch = void 0;
|
|
49
|
+
const SwitchPrimitive = __importStar(require("@radix-ui/react-switch"));
|
|
50
|
+
const React = __importStar(require("react"));
|
|
51
|
+
const utils_1 = require("../../helpers/utils");
|
|
52
|
+
const Switch = React.forwardRef((_a, ref) => {
|
|
53
|
+
var { className, icon } = _a, props = __rest(_a, ["className", "icon"]);
|
|
54
|
+
return (React.createElement(SwitchPrimitive.Root, Object.assign({ className: (0, utils_1.cn)('peer relative inline-flex h-5 w-9 shrink-0 cursor-pointer items-center rounded-sm border-2 border-transparent shadow-sm transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=unchecked]:bg-input', className) }, props, { ref: ref }),
|
|
55
|
+
React.createElement(SwitchPrimitive.Thumb, { className: (0, utils_1.cn)('pointer-events-none flex items-center justify-center h-4 w-4 rounded-sm bg-background shadow-lg ring-0 transition-transform data-[state=checked]:translate-x-4 data-[state=unchecked]:translate-x-0') }, icon)));
|
|
56
|
+
});
|
|
57
|
+
exports.Switch = Switch;
|
|
58
|
+
Switch.displayName = SwitchPrimitive.Root.displayName;
|
package/package.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{
|
|
2
|
-
"version": "0.0.
|
|
2
|
+
"version": "0.0.774",
|
|
3
3
|
"name": "ag-common",
|
|
4
4
|
"main": "./dist/index.js",
|
|
5
5
|
"types": "./dist/index.d.ts",
|
|
@@ -17,70 +17,71 @@
|
|
|
17
17
|
"test": "globstar -- node --import tsx --test \"src/**/*.test.ts\""
|
|
18
18
|
},
|
|
19
19
|
"dependencies": {
|
|
20
|
-
"@aws-sdk/client-apigatewaymanagementapi": "^3.
|
|
21
|
-
"@aws-sdk/client-dynamodb": "^3.
|
|
22
|
-
"@aws-sdk/client-s3": "^3.
|
|
23
|
-
"@aws-sdk/client-ses": "^3.
|
|
24
|
-
"@aws-sdk/client-sqs": "^3.
|
|
25
|
-
"@aws-sdk/client-sts": "^3.
|
|
26
|
-
"@aws-sdk/lib-dynamodb": "^3.
|
|
27
|
-
"@aws-sdk/s3-presigned-post": "^3.
|
|
20
|
+
"@aws-sdk/client-apigatewaymanagementapi": "^3.901.0",
|
|
21
|
+
"@aws-sdk/client-dynamodb": "^3.901.0",
|
|
22
|
+
"@aws-sdk/client-s3": "^3.901.0",
|
|
23
|
+
"@aws-sdk/client-ses": "^3.901.0",
|
|
24
|
+
"@aws-sdk/client-sqs": "^3.901.0",
|
|
25
|
+
"@aws-sdk/client-sts": "^3.901.0",
|
|
26
|
+
"@aws-sdk/lib-dynamodb": "^3.901.0",
|
|
27
|
+
"@aws-sdk/s3-presigned-post": "^3.901.0",
|
|
28
28
|
"@azure/cosmos": "^4.5.1",
|
|
29
29
|
"@storybook/addon-styling-webpack": "^2.0.0",
|
|
30
30
|
"@storybook/react-vite": "^9.1.10",
|
|
31
|
-
"aws-cdk-lib": "^2.
|
|
31
|
+
"aws-cdk-lib": "^2.219.0",
|
|
32
32
|
"buffer": "^6.0.3",
|
|
33
33
|
"jsonwebtoken": "^9.0.2",
|
|
34
34
|
"jwks-rsa": "^3.2.0",
|
|
35
35
|
"node-cache": "^5.1.2",
|
|
36
|
-
"react": "^19.
|
|
37
|
-
"react-dom": "^19.
|
|
38
|
-
"typescript": "^5.9.
|
|
36
|
+
"react": "^19.2.0",
|
|
37
|
+
"react-dom": "^19.2.0",
|
|
38
|
+
"typescript": "^5.9.3"
|
|
39
39
|
},
|
|
40
40
|
"devDependencies": {
|
|
41
41
|
"@emotion/react": "^11.14.0",
|
|
42
42
|
"@emotion/styled": "^11.14.1",
|
|
43
|
-
"@radix-ui/react-accordion": "1.2.12",
|
|
44
|
-
"@radix-ui/react-avatar": "1.1.10",
|
|
45
|
-
"@radix-ui/react-checkbox": "1.3.3",
|
|
46
|
-
"@radix-ui/react-dialog": "1.1.15",
|
|
47
|
-
"@radix-ui/react-dropdown-menu": "2.1.16",
|
|
48
|
-
"@radix-ui/react-icons": "1.3.2",
|
|
49
|
-
"@radix-ui/react-label": "2.1.7",
|
|
50
|
-
"@radix-ui/react-popover": "1.1.15",
|
|
51
|
-
"@radix-ui/react-scroll-area": "1.2.10",
|
|
52
|
-
"@radix-ui/react-select": "2.2.6",
|
|
53
|
-
"@radix-ui/react-slot": "1.2.3",
|
|
54
|
-
"@
|
|
55
|
-
"@
|
|
56
|
-
"@storybook/addon-
|
|
43
|
+
"@radix-ui/react-accordion": "^1.2.12",
|
|
44
|
+
"@radix-ui/react-avatar": "^1.1.10",
|
|
45
|
+
"@radix-ui/react-checkbox": "^1.3.3",
|
|
46
|
+
"@radix-ui/react-dialog": "^1.1.15",
|
|
47
|
+
"@radix-ui/react-dropdown-menu": "^2.1.16",
|
|
48
|
+
"@radix-ui/react-icons": "^1.3.2",
|
|
49
|
+
"@radix-ui/react-label": "^2.1.7",
|
|
50
|
+
"@radix-ui/react-popover": "^1.1.15",
|
|
51
|
+
"@radix-ui/react-scroll-area": "^1.2.10",
|
|
52
|
+
"@radix-ui/react-select": "^2.2.6",
|
|
53
|
+
"@radix-ui/react-slot": "^1.2.3",
|
|
54
|
+
"@radix-ui/react-switch": "^1.2.6",
|
|
55
|
+
"@smithy/types": "^4.6.0",
|
|
56
|
+
"@storybook/addon-docs": "^9.1.10",
|
|
57
|
+
"@storybook/addon-links": "^9.1.10",
|
|
57
58
|
"@storybook/addons": "^7.6.17",
|
|
58
59
|
"@storybook/manager-api": "^8.6.14",
|
|
59
|
-
"@storybook/react": "^9.1.
|
|
60
|
-
"@storybook/react-webpack5": "^9.1.
|
|
60
|
+
"@storybook/react": "^9.1.10",
|
|
61
|
+
"@storybook/react-webpack5": "^9.1.10",
|
|
61
62
|
"@storybook/theming": "^8.6.14",
|
|
62
|
-
"@tailwindcss/postcss": "4.1.
|
|
63
|
+
"@tailwindcss/postcss": "^4.1.14",
|
|
63
64
|
"@types/jsonwebtoken": "^9.0.10",
|
|
64
|
-
"@types/node": "^24.
|
|
65
|
-
"@types/react": "^19.
|
|
66
|
-
"@types/react-dom": "^19.
|
|
67
|
-
"@typescript-eslint/eslint-plugin": "^8.
|
|
68
|
-
"@typescript-eslint/parser": "^8.
|
|
69
|
-
"autoprefixer": "10.4.21",
|
|
65
|
+
"@types/node": "^24.6.2",
|
|
66
|
+
"@types/react": "^19.2.0",
|
|
67
|
+
"@types/react-dom": "^19.2.0",
|
|
68
|
+
"@typescript-eslint/eslint-plugin": "^8.45.0",
|
|
69
|
+
"@typescript-eslint/parser": "^8.45.0",
|
|
70
|
+
"autoprefixer": "^10.4.21",
|
|
70
71
|
"class-variance-authority": "^0.7.1",
|
|
71
72
|
"clsx": "^2.1.1",
|
|
72
|
-
"cross-env": "^10.
|
|
73
|
-
"eslint": "^9.
|
|
74
|
-
"eslint-config-e7npm": "^0.1.
|
|
75
|
-
"eslint-plugin-storybook": "^9.1.
|
|
73
|
+
"cross-env": "^10.1.0",
|
|
74
|
+
"eslint": "^9.36.0",
|
|
75
|
+
"eslint-config-e7npm": "^0.1.25",
|
|
76
|
+
"eslint-plugin-storybook": "^9.1.10",
|
|
76
77
|
"globstar": "^1.0.0",
|
|
77
78
|
"lucide-react": "^0.544.0",
|
|
78
79
|
"rimraf": "^6.0.1",
|
|
79
|
-
"storybook": "^9.1.
|
|
80
|
-
"tailwind-merge": "3.3.1",
|
|
81
|
-
"tailwindcss": "4.1.
|
|
82
|
-
"tailwindcss-animate": "1.0.7",
|
|
83
|
-
"tsx": "^4.20.
|
|
80
|
+
"storybook": "^9.1.10",
|
|
81
|
+
"tailwind-merge": "^3.3.1",
|
|
82
|
+
"tailwindcss": "^4.1.14",
|
|
83
|
+
"tailwindcss-animate": "^1.0.7",
|
|
84
|
+
"tsx": "^4.20.6"
|
|
84
85
|
},
|
|
85
86
|
"resolutions": {
|
|
86
87
|
"globals": "16.4.0"
|