@unframed/cli 1.0.0-rc.1 → 1.0.0-rc.2
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/package.json
CHANGED
package/registry.json
CHANGED
package/skill/unframed/SKILL.md
CHANGED
|
@@ -5,7 +5,7 @@ description: Builds UI with Unframed web components (@unframed/core, @unframed/r
|
|
|
5
5
|
|
|
6
6
|
# Unframed UI
|
|
7
7
|
|
|
8
|
-
Unframed 1.0.0-rc.
|
|
8
|
+
Unframed 1.0.0-rc.2: accessible UI components as standard custom elements (Lit). Every tag starts with `uf-`. They work in plain HTML and every framework; React, Vue and Angular have wrapper packages for typed props, events and form bindings.
|
|
9
9
|
|
|
10
10
|
## Before writing code
|
|
11
11
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# Using Unframed 1.0.0-rc.
|
|
1
|
+
# Using Unframed 1.0.0-rc.2 in each framework
|
|
2
2
|
|
|
3
3
|
## HTML & JavaScript
|
|
4
4
|
|
|
@@ -42,7 +42,7 @@ Form controls join the surrounding `<form>` like native ones: `required`, `FormD
|
|
|
42
42
|
```
|
|
43
43
|
|
|
44
44
|
```js
|
|
45
|
-
import { toast } from '@unframed/core';
|
|
45
|
+
import { toast } from '@unframed/core/toast';
|
|
46
46
|
|
|
47
47
|
const form = document.querySelector('#signup');
|
|
48
48
|
const dialog = document.querySelector('#welcome');
|
|
@@ -68,8 +68,8 @@ dialog.addEventListener('uf-hide', () => toast('Welcome aboard!', { variant: 'su
|
|
|
68
68
|
<!doctype html>
|
|
69
69
|
<html lang="en">
|
|
70
70
|
<head>
|
|
71
|
-
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@unframed/tokens@1.0.0-rc.
|
|
72
|
-
<script type="module" src="https://cdn.jsdelivr.net/npm/@unframed/core@1.0.0-rc.
|
|
71
|
+
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@unframed/tokens@1.0.0-rc.2/dist/tokens.css" />
|
|
72
|
+
<script type="module" src="https://cdn.jsdelivr.net/npm/@unframed/core@1.0.0-rc.2/+esm"></script>
|
|
73
73
|
</head>
|
|
74
74
|
<body>
|
|
75
75
|
<uf-button variant="primary">It works</uf-button>
|
|
@@ -111,7 +111,8 @@ Props are the element's properties. Events: `onInput` and `onChange` for form co
|
|
|
111
111
|
|
|
112
112
|
```tsx
|
|
113
113
|
import { useState } from 'react';
|
|
114
|
-
import {
|
|
114
|
+
import type { UfCheckbox as UfCheckboxElement, UfInput as UfInputElement } from '@unframed/core';
|
|
115
|
+
import { toast } from '@unframed/core/toast';
|
|
115
116
|
import { UfButton, UfCheckbox, UfDialog, UfInput } from '@unframed/react';
|
|
116
117
|
|
|
117
118
|
export function Signup() {
|
|
@@ -212,7 +213,7 @@ createApp(App).mount('#app');
|
|
|
212
213
|
```vue
|
|
213
214
|
<script setup lang="ts">
|
|
214
215
|
import { ref } from 'vue';
|
|
215
|
-
import { toast } from '@unframed/core';
|
|
216
|
+
import { toast } from '@unframed/core/toast';
|
|
216
217
|
import { UfButton, UfCheckbox, UfDialog, UfInput } from '@unframed/vue';
|
|
217
218
|
|
|
218
219
|
const email = ref('');
|
|
@@ -285,7 +286,7 @@ Outputs keep the event names: `(input)`, `(change)`, `(uf-hide)`. `UNFRAMED` imp
|
|
|
285
286
|
```ts
|
|
286
287
|
import { Component, signal } from '@angular/core';
|
|
287
288
|
import { FormControl, FormGroup, ReactiveFormsModule, Validators } from '@angular/forms';
|
|
288
|
-
import { toast } from '@unframed/core';
|
|
289
|
+
import { toast } from '@unframed/core/toast';
|
|
289
290
|
import { UNFRAMED } from '@unframed/angular';
|
|
290
291
|
|
|
291
292
|
@Component({
|