Przejdź do treści
Biblioteka skilli
Projektowanie i UX · Budowanie i kod

spectrum-web-components

/spectrum-web-components

Buduje interfejsy z Spectrum Web Components, czyli elementów sp-* w wersji Spectrum 1, z opisem API i dostępności.

Licencja
Apache-2.0
Ostatnia zmiana repozytorium
27.10.2026

Ocena i bezpieczeństwo

95/ 100Klasa: dobry
Format20 / 25
Frontmatter z nazwą i opisem, poprawna nazwa, opis do 1024 znaków, nazwa zgodna z folderem.
Odkrywalność25 / 25
Opis mówi, kiedy użyć skilla, ma sensowną długość i jest w 3. osobie.
Treść35 / 35
Co najmniej 150 słów i do 500 linii, nagłówki, listy kroków, przykłady albo kod.
Higiena15 / 15
Bez zaślepek typu TODO, bez ścieżek Windows, z licencją.
Ryzykobrak sygnałów w skanie
Pliki w paczce
1
Skrypty
0
Komentarze HTML
0
Adresy URL w SKILL.md
1
Przestarzałość

Brak sygnałów. Repozytorium zmienione 27.10.2026, bez odwołań do wycofanych modeli i API.

Licencja

Apache-2.0, otwarta: można używać i zmieniać, z zachowaniem licencji i informacji o zmianach.

Co robi i kiedy

Buduje interfejsy z Spectrum Web Components, czyli elementów sp-* w wersji Spectrum 1, z opisem API i dostępności.

Oryginalny opis (EN)

Build UIs with Spectrum Web Components (SWC), Adobe's Spectrum 1 web component library. Use when developers are working with @spectrum-web-components/* packages or sp-* custom elements. Includes component API references, usage examples, accessibility guidance, and integration guides.

Jak działa

  1. Quick start
  2. Key concepts
  3. Documentation structure
Sekcje z nagłówków SKILL.md, w oryginale · 87 linii, 350 słów
Podgląd SKILL.md
---
name: 'spectrum-web-components'
description: "Build UIs with Spectrum Web Components (SWC), Adobe's Spectrum 1 web component library. Use when developers are working with @spectrum-web-components/* packages or sp-* custom elements. Includes component API references, usage examples, accessibility guidance, and integration guides."
license: 'Apache-2.0'
metadata:
  author: 'Adobe'
  website: 'https://opensource.adobe.com/spectrum-web-components/'
---

# Spectrum Web Components (Spectrum 1)

Spectrum Web Components (SWC) is Adobe's Spectrum 1 design system implemented as
framework-agnostic web components. Elements are prefixed with `sp-` and each ships
as an independent npm package under `@spectrum-web-components`.

> **Upgrading to Spectrum 2?** Use the `migrate-swc-gen1-to-gen2` skill instead,
> which includes per-component migration guides and a full coexistence walkthrough.

## Quick start

Install the components you need (each component is its own package):

```bash
yarn add @spectrum-web-components/theme \
         @spectrum-web-components/button \
         @spectrum-web-components/badge
```

All `sp-*` components must be wrapped in `<sp-theme>` to receive Spectrum CSS tokens:

```html
<script type="module">
  import '@spectrum-web-components/theme/sp-theme.js';
  import '@spectrum-web-components/theme/scale-medium.js';
  import '@spectrum-web-components/theme/theme-light.js';
  import '@spectrum-web-components/button/sp-button.js';
</script>

<sp-theme system="spectrum" scale="medium" color="light">
  <sp-button variant="accent">Save</sp-button>
</sp-theme>
```

## Key concepts

- **`<sp-theme>`** is required — it provides all design tokens (color, scale, spacing,
  typography) to descendant `sp-*` elements via CSS custom properties. See
  [What is a theme?](references/guides/what-is-a-theme.md) for a full explanation of
  `system`, `color`, `scale`, `direction`, and `language` attributes.

- **Per-package install** — each component (`@spectrum-web-components/button`,
  `@spectrum-web-components/badge`, etc.) is imported separately so your bundle only
  includes what you use.

- **Side-effectful import** — importing the `.js` entry registers the custom element:

  ```ts
  import '@spectrum-web-components/button/sp-button.js';
  ```

  Import the class directly for extension or typing:

  ```ts
  import { Button } from '@spectrum-web-components/button';
  ```

- **Spectrum 2 theme bridge** — apply `system="spectrum-two"` to `<sp-theme>` to
  adopt Spectrum 2 visual tokens on Gen 1 components. This is useful when running
  Gen 1 and Gen 2 side-by-side during a gradual migration.

- **React** — use `@swc-react/*` wrapper packages for first-class React event
  handling. See [Using SWC with React](references/guides/using-swc-react.md).

- **Accessibility** — `sp-*` components expose correct ARIA roles, labels, and
  keyboard navigation. Labels are typically provided via the `label` attribute or
  the default slot; see each component's API reference for specifics.

## Documentation structure

The `references/` directory contains guides and one Markdown file per component.
Read the component file for its API, slots, events, CSS custom properties, and usage examples.

### Guides

{{GUIDE_LIST}}

### Components

One file per component in `references/components/` (e.g. `references/components/sp-badge.md`).
Read the file for props, slots, events, CSS custom properties, and usage examples.

Available components: {{COMPONENT_NAMES}}.

{{COMPONENT_LIST}}

Wersje

W bazie nie ma innych skilli o nazwie spectrum-web-components.

Migawka bazy z 28.10.2026 · wersja paczki 5c6b8efa76e8 (skrót SHA-256 całej paczki)

Zgłoś problem z tym skillem: szkodliwa treść, błędny opis albo prośba autora o usunięcie.

Podobne skille

  • 95spectrum-wc
    Buduje interfejsy ze Spectrum 2 Web Components, czyli elementów swc-*, z opisem właściwości, slotów i zdarzeń.
  • 95migrate-swc-gen1-to-gen2
    Migruje komponenty Spectrum 1, czyli elementy sp-* i pakiety @spectrum-web-components, na Spectrum 2.
  • 100s2-docs
    Wyszukuje dokumentację i wytyczne komponentów Spectrum 2 dla React Spectrum i Spectrum Web Components, żeby prototyp nie odbiegał od projektu.
  • 100design-data
    Wyszukuje tokeny projektowe, schematy komponentów i decyzje systemu Adobe Spectrum, pomagając walidować i eksplorować dane tokenów oraz obsługując CLI design-data.
  • 90ability-spectrum-mapping
    Mapuje, jak produkt działa w całym spektrum ludzkich możliwości i potrzeb, i planuje zakres dostępności.
  • 100appbuilder-ui-scaffolder
    Generuje komponenty React Spectrum dla Adobe Experience Cloud Shell i rozszerzeń AEM UI: strony, formularze, tabele danych, okna dialogowe i nawigacja.

Uwagi i zgłoszenia

Wiadomość trafi do Bartosza Sokolińskiego. Adres e-mail jest potrzebny tylko do odpowiedzi. Szczegóły w polityce prywatności.