-
Notifications
You must be signed in to change notification settings - Fork 60
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
79849bc
commit ee8f6fc
Showing
19 changed files
with
422 additions
and
307 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
node_modules | ||
dist |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
const base = require('@iot-app-kit/eslint-config'); | ||
|
||
module.exports = { | ||
...base, | ||
root: true, | ||
settings: { | ||
...base.settings, | ||
'import/resolver': { | ||
...base.settings['import/resolver'], | ||
typescript: { | ||
...base.settings['import/resolver'].typescript, | ||
project: ['packages/atoms/tsconfig.json'], | ||
}, | ||
node: { | ||
project: ['packages/atoms/tsconfig.json'], | ||
}, | ||
}, | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
{ | ||
"name": "@iot-app-kit/atoms", | ||
"version": "12.2.1", | ||
"private": true, | ||
"type": "module", | ||
"main": "./dist/cjs/index.cjs.js", | ||
"module": "./dist/esm/index.js", | ||
"types": "./dist/esm/index.d.ts", | ||
"exports": { | ||
".": { | ||
"@iot-app-kit/development": "./src/index.ts", | ||
"default": { | ||
"types": "./dist/esm/index.d.ts", | ||
"require": "./dist/cjs/index.cjs.js", | ||
"import": "./dist/esm/index.js", | ||
"default": "./dist/esm/index.js" | ||
} | ||
} | ||
}, | ||
"scripts": { | ||
"build": "NODE_OPTIONS='--import tsx/esm' vite build", | ||
"postbuild": "iot-postbuild", | ||
"clean": "npx rimraf .cache dist", | ||
"clean:turbo": "npx rimraf .turbo", | ||
"clean:nuke": "npm run clean && npm run clean:turbo && npx rimraf node_modules", | ||
"lint": "eslint . --max-warnings=0 --cache --cache-location .cache/eslint/", | ||
"fix": "eslint --fix . --cache --cache-location ./cache/eslint/", | ||
"test:typescript": "tsc --noEmit" | ||
}, | ||
"peerDependencies": { | ||
"react": "^18", | ||
"react-dom": "^18" | ||
}, | ||
"devDependencies": { | ||
"@iot-app-kit/eslint-config": "*", | ||
"@iot-app-kit/ts-config": "*", | ||
"@iot-app-kit/vite-config": "*", | ||
"@types/node": "^18.16.18", | ||
"@types/react": "^18.2.12", | ||
"@types/react-dom": "^18.2.5", | ||
"react": "^18.2.0", | ||
"react-dom": "^18.2.0", | ||
"rimraf": "^5.0.1", | ||
"tsx": "^4.19.2", | ||
"type-fest": "^4.28.1", | ||
"typescript": "^5.5.4", | ||
"vite": "^5.4.11" | ||
}, | ||
"dependencies": { | ||
"@cloudscape-design/components": "3.0.693" | ||
}, | ||
"iotAppKit": { | ||
"scope": "protected" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
import CloudscapeButton from '@cloudscape-design/components/button'; | ||
import { memo, type PropsWithChildren } from 'react'; | ||
|
||
export interface ButtonProps extends PropsWithChildren { | ||
type: 'primary'; | ||
onClick: VoidFunction; | ||
} | ||
|
||
export const Button = memo(({ type, onClick, children }: ButtonProps) => { | ||
return ( | ||
<CloudscapeButton variant={type} onClick={onClick}> | ||
{children} | ||
</CloudscapeButton> | ||
); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
export { Button, type ButtonProps } from './buttons/button'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
{ | ||
"$schema": "https://json.schemastore.org/tsconfig", | ||
"extends": "@iot-app-kit/ts-config/tsconfig.base.json", | ||
"include": ["src"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
import { definePackageConfig } from '@iot-app-kit/vite-config/definePackageConfig'; | ||
|
||
export default definePackageConfig({ | ||
iotAppKitPackage: { dirname: __dirname }, | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.