@pure-ds/core 0.4.36 → 0.4.37
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/getting-started.md +33 -6
- package/package.json +1 -1
- package/readme.md +20 -12
package/getting-started.md
CHANGED
|
@@ -48,6 +48,32 @@ await PDS.start(config); // That's it! Start writing semantic HTML.
|
|
|
48
48
|
# Create or regenerate config with examples
|
|
49
49
|
npx pds-init-config
|
|
50
50
|
|
|
51
|
+
# Update AI assistant instructions
|
|
52
|
+
npx pds-setup-copilot
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
---
|
|
56
|
+
|
|
57
|
+
## 🤖 AI Assistant Integration (GitHub Copilot, Cursor, etc.)
|
|
58
|
+
|
|
59
|
+
**PDS includes comprehensive LLM instructions that teach AI assistants to use PDS patterns correctly.**
|
|
60
|
+
|
|
61
|
+
During installation, instructions are automatically copied to:
|
|
62
|
+
- `.github/copilot-instructions.md` (GitHub Copilot)
|
|
63
|
+
- `.cursorrules` (Cursor AI)
|
|
64
|
+
|
|
65
|
+
These instructions teach your AI to:
|
|
66
|
+
- ✅ Reference actual source files (`custom-elements.json`, `pds.css-data.json`, `pds-ontology.js`) instead of guessing
|
|
67
|
+
- ✅ Use PDS primitives (`.card`, `.btn-primary`, etc.) instead of creating custom CSS
|
|
68
|
+
- ✅ Apply progressive enhancements (`data-dropdown`, `data-toggle`) correctly
|
|
69
|
+
- ✅ Use web components only when necessary (`<pds-tabstrip>`, `<pds-form>`)
|
|
70
|
+
- ✅ Follow PDS best practices for forms, toasts, dialogs, and more
|
|
71
|
+
|
|
72
|
+
**To manually install or update:**
|
|
73
|
+
|
|
74
|
+
```bash
|
|
75
|
+
npx pds-setup-copilot
|
|
76
|
+
|
|
51
77
|
# Force overwrite existing config
|
|
52
78
|
npx pds-init-config --force
|
|
53
79
|
```
|
|
@@ -316,14 +342,15 @@ PDS components auto-load when used:
|
|
|
316
342
|
|
|
317
343
|
<!-- Tabs -->
|
|
318
344
|
<pds-tabstrip>
|
|
319
|
-
<
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
<
|
|
345
|
+
<pds-tabpanel label="Overview">
|
|
346
|
+
<p>Overview content</p>
|
|
347
|
+
</pds-tabpanel>
|
|
348
|
+
<pds-tabpanel label="Details">
|
|
349
|
+
<p>Details content</p>
|
|
350
|
+
</pds-tabpanel>
|
|
323
351
|
</pds-tabstrip>
|
|
324
352
|
|
|
325
|
-
<!-- Toast notifications -->
|
|
326
|
-
<pds-toaster id="toaster"></pds-toaster>
|
|
353
|
+
<!-- Toast notifications (auto-created, no manual setup needed) -->
|
|
327
354
|
<script>
|
|
328
355
|
PDS.toast("Saved successfully!", { type: "success" });
|
|
329
356
|
</script>
|
package/package.json
CHANGED
package/readme.md
CHANGED
|
@@ -628,11 +628,12 @@ Methods:
|
|
|
628
628
|
**`<pds-tabstrip>`** - Accessible tab interface
|
|
629
629
|
```html
|
|
630
630
|
<pds-tabstrip>
|
|
631
|
-
<
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
<
|
|
635
|
-
|
|
631
|
+
<pds-tabpanel label="Overview">
|
|
632
|
+
<p>Overview content</p>
|
|
633
|
+
</pds-tabpanel>
|
|
634
|
+
<pds-tabpanel label="Details">
|
|
635
|
+
<p>Details content</p>
|
|
636
|
+
</pds-tabpanel>
|
|
636
637
|
</pds-tabstrip>
|
|
637
638
|
```
|
|
638
639
|
|
|
@@ -663,14 +664,21 @@ Events:
|
|
|
663
664
|
|
|
664
665
|
**`<pds-toaster>`** - Toast notifications
|
|
665
666
|
```html
|
|
666
|
-
|
|
667
|
-
|
|
667
|
+
<!-- No manual setup needed - PDS.toast() auto-creates the component -->
|
|
668
668
|
<script>
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
669
|
+
// Simple usage
|
|
670
|
+
await PDS.toast('Saved successfully!', { type: 'success' });
|
|
671
|
+
|
|
672
|
+
// With custom duration
|
|
673
|
+
await PDS.toast('Processing...', {
|
|
674
|
+
type: 'information',
|
|
675
|
+
duration: 5000
|
|
676
|
+
});
|
|
677
|
+
|
|
678
|
+
// Persistent (must be manually closed)
|
|
679
|
+
await PDS.toast('Important notice', {
|
|
680
|
+
type: 'warning',
|
|
681
|
+
persistent: true
|
|
674
682
|
});
|
|
675
683
|
</script>
|
|
676
684
|
```
|