@capillarytech/blaze-ui 5.4.1 → 5.6.0
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.
- package/CapAskAira/index.js +312 -341
- package/CapAskAira/index.js.map +1 -1
- package/CapExpressionEditor/README.md +32 -0
- package/CapExpressionEditor/index.d.ts +1654 -0
- package/CapExpressionEditor/index.d.ts.map +1 -0
- package/CapExpressionEditor/index.js +312 -349
- package/CapExpressionEditor/index.js.map +1 -1
- package/CapExpressionEditor/js/fixGrammar.d.ts +3 -0
- package/CapExpressionEditor/js/fixGrammar.d.ts.map +1 -0
- package/CapExpressionEditor/js/grammar.d.ts +1628 -0
- package/CapExpressionEditor/js/grammar.d.ts.map +1 -0
- package/CapExpressionEditor/types.d.ts +18 -0
- package/CapExpressionEditor/types.d.ts.map +1 -0
- package/CapLevelGraphRenderer/index.js +130 -127
- package/CapLevelGraphRenderer/index.js.map +1 -1
- package/index.d.ts +2 -2
- package/index.d.ts.map +1 -1
- package/index.js +4352 -1108
- package/index.js.map +1 -1
- package/package.json +3 -3
- package/.npmrc +0 -2
- package/CapLevelGraphRenderer/CapLevelGraphRenderer-test-cases.md +0 -50
- package/CapLevelGraphRenderer/README.md +0 -123
- package/CapLevelGraphRenderer/Tooltip.d.ts +0 -24
- package/CapLevelGraphRenderer/Tooltip.d.ts.map +0 -1
- package/CapLevelGraphRenderer/Tooltip_MIGRATION_ANALYSIS.md +0 -120
- package/CapLevelGraphRenderer/index.d.ts +0 -16
- package/CapLevelGraphRenderer/index.d.ts.map +0 -1
- package/CapLevelGraphRenderer/types.d.ts +0 -151
- package/CapLevelGraphRenderer/types.d.ts.map +0 -1
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
# CapExpressionEditor
|
|
2
|
+
|
|
3
|
+
Expression editor component with grammar validation, syntax highlighting, and autocomplete. Uses a jQuery-based expredit plugin for parsing and validation.
|
|
4
|
+
|
|
5
|
+
## Migration Notes (Antd v3 → v6)
|
|
6
|
+
|
|
7
|
+
### Changes Applied
|
|
8
|
+
|
|
9
|
+
- **Runtime prop validation removed**: Replaced with TypeScript types from `types.ts`
|
|
10
|
+
- **defaultProps removed**: Default values now use destructuring in function arguments
|
|
11
|
+
- **Class → Functional component**: Converted to React.FC with hooks
|
|
12
|
+
- **SCSS**: Hardcoded colors replaced with `$CAP_*` design tokens from `_variables.scss`
|
|
13
|
+
- **No Antd overrides**: Component uses `CapInput.TextArea` (wraps Antd Input); no theme config changes required
|
|
14
|
+
|
|
15
|
+
### Props
|
|
16
|
+
|
|
17
|
+
| Prop | Type | Default | Description |
|
|
18
|
+
|------|------|---------|-------------|
|
|
19
|
+
| `grammar` | `ExpressionGrammar` | defaultGrammar | Expression grammar configuration |
|
|
20
|
+
| `expected` | `string[]` | `['boolean']` | Expected types for validation |
|
|
21
|
+
| `typeSource` | `string` | - | Type source identifier |
|
|
22
|
+
| `delims` | `string[]` | `['{{', '}}']` | Delimiters for expression parsing |
|
|
23
|
+
| `expression` | `string` | `''` | Initial expression value |
|
|
24
|
+
| `onChange` | `(expressionJSON, expression, isError) => void` | - | Callback when expression changes |
|
|
25
|
+
| `className` | `string` | - | Additional CSS class |
|
|
26
|
+
| `disabled` | `boolean` | - | Disable the editor |
|
|
27
|
+
| ...rest | `CapInputTextAreaProps` | - | Passed through to underlying TextArea |
|
|
28
|
+
|
|
29
|
+
### Dependencies
|
|
30
|
+
|
|
31
|
+
- **jquery** (^3.6.0): Required for expredit plugin
|
|
32
|
+
- **rangy** (^1.3.2): Selection/range library used by expredit plugin
|