diff --git a/README.md b/README.md new file mode 100644 index 0000000..638b956 --- /dev/null +++ b/README.md @@ -0,0 +1,12 @@ +## Philosophy + +Accesibility shouldn't be a choice, it should be a given. This library tries to be a mirror of the [WAI-ARIA patterns](https://www.w3.org/WAI/ARIA/apg/patterns/). This library effectively export these accesible atoms to be extended with application specific needs but disregarding the accesibility aspect + +## Characteristics + +- It completely complies to WAI-ARIA specifications +- It's framework agnostic + +## Modules + +- [button](packages/button/README.md) diff --git a/apps/playground/index.html b/apps/playground/index.html index eb640dc..738e8ac 100644 --- a/apps/playground/index.html +++ b/apps/playground/index.html @@ -14,12 +14,7 @@ - diff --git a/packages/button/README.md b/packages/button/README.md index 92f0d33..0adddd0 100644 --- a/packages/button/README.md +++ b/packages/button/README.md @@ -1 +1,31 @@ -# @ariabones/button +## toggle + +### installation + +``` +npm install @ariabones/button +yarn add @ariabones/button +pnpm install @ariabones/button +``` + +### usage + +```html + +``` + +### api + +| property | type | default | description | +| ------------ | ----------------- | ------- | --------------------------------------------------- | +| data-pressed | "true" or "false" | "false" | used to set up the initial value of aria-pressed | +| aria-pressed | "true" or "false" | "false" | indicates if the button is currently pressed or not | + +### keyboard interaction + +| key | description | +| ----- | ------------------ | +| Space | toggles the button | +| Enter | toggles the button |