mirror of
https://github.com/webstudio-is/webstudio.git
synced 2026-11-08 13:05:08 +09:00
https://github.com/webstudio-is/webstudio-builder/issues/84#issuecomment-1522834976 ## Description 1. Added new components: - textarea - radio-button and radio-button-field - checkbox and checkbox-field - success-message - error-message 2. Added `states` like `:disabled`, `:valid`, etc. to `input` 3. Added `custom-components/form` that renders success-message and error-message conditionally 4. Added `success` and `error` style states to `custom-components/form` 5. Style panel now shows "Select an instance on the canvas" if the selected component is not rendered on canvas (e.g. error-message may not be rendered) Not in this PR: - The mailer package - Backend handler for forms (will be in a PR in SAAS) - Logic in Form that actually submits to backend and shows success/error messages ## Steps for reproduction 1. Add a "Form" to canvas 2. Add "Checkbox Field", "Radio Button Field", "Text Area" to the form 3. Try changing `initialState` property of the form
78 lines
2.5 KiB
JSON
78 lines
2.5 KiB
JSON
{
|
|
"name": "@webstudio-is/react-sdk",
|
|
"version": "0.61.0",
|
|
"description": "Webstudio JavaScript / TypeScript API",
|
|
"author": "Webstudio <github@webstudio.is>",
|
|
"homepage": "https://webstudio.is",
|
|
"type": "module",
|
|
"scripts": {
|
|
"dev": "build-package --watch",
|
|
"build": "build-package",
|
|
"build:args": "generate-arg-types './src/components/*.tsx ./src/app/custom-components/*.tsx !./src/**/*.stories.tsx !./src/**/*.ws.tsx' && prettier --write \"**/*.props.ts\"",
|
|
"dts": "tsc --declarationDir lib/types",
|
|
"typecheck": "tsc --noEmit --emitDeclarationOnly false",
|
|
"test": "NODE_OPTIONS=--experimental-vm-modules jest --passWithNoTests",
|
|
"lint": "eslint ./src --ext .ts,.tsx --max-warnings 0",
|
|
"checks": "pnpm typecheck && pnpm lint && pnpm test",
|
|
"storybook:run": "start-storybook -p 6006",
|
|
"storybook:build": "build-storybook"
|
|
},
|
|
"devDependencies": {
|
|
"@babel/core": "^7.21.0",
|
|
"@jest/globals": "^29.3.1",
|
|
"@remix-run/react": "^1.15.0",
|
|
"@storybook/react": "^6.5.16",
|
|
"@types/react": "^18.0.35",
|
|
"@types/react-dom": "^18.0.11",
|
|
"@webstudio-is/jest-config": "workspace:^",
|
|
"@webstudio-is/scripts": "workspace:^",
|
|
"@webstudio-is/storybook-config": "workspace:^",
|
|
"@webstudio-is/tsconfig": "workspace:^",
|
|
"jest": "^29.3.1",
|
|
"react": "^18.2.0",
|
|
"react-dom": "^18.2.0",
|
|
"typescript": "5.0.3",
|
|
"zod": "^3.19.1"
|
|
},
|
|
"peerDependencies": {
|
|
"@remix-run/react": "^1.15.0",
|
|
"react": "^18.2.0",
|
|
"react-dom": "^18.2.0",
|
|
"zod": "^3.19.1"
|
|
},
|
|
"dependencies": {
|
|
"@nanostores/react": "^0.4.1",
|
|
"@webstudio-is/asset-uploader": "workspace:^",
|
|
"@webstudio-is/css-data": "workspace:^",
|
|
"@webstudio-is/css-engine": "workspace:^",
|
|
"@webstudio-is/css-vars": "workspace:^",
|
|
"@webstudio-is/fonts": "workspace:^",
|
|
"@webstudio-is/generate-arg-types": "workspace:^",
|
|
"@webstudio-is/icons": "workspace:^",
|
|
"@webstudio-is/image": "workspace:^",
|
|
"@webstudio-is/prisma-client": "workspace:^",
|
|
"@webstudio-is/project-build": "workspace:^",
|
|
"detect-font": "^0.1.5",
|
|
"html-tags": "^3.2.0",
|
|
"nanoevents": "^7.0.1",
|
|
"nanoid": "^3.2.0",
|
|
"nanostores": "^0.7.1"
|
|
},
|
|
"exports": {
|
|
".": {
|
|
"source": "./src/index.ts",
|
|
"import": "./lib/index.js",
|
|
"require": "./lib/cjs/index.js"
|
|
}
|
|
},
|
|
"types": "lib/types/index.d.ts",
|
|
"files": [
|
|
"lib/*",
|
|
"src/*",
|
|
"!*.test.*"
|
|
],
|
|
"license": "MIT",
|
|
"private": false,
|
|
"sideEffects": false
|
|
}
|