Skip to content

Commit

Permalink
chore: 🤖 release v11.2.0
Browse files Browse the repository at this point in the history
  • Loading branch information
phun-ky committed Nov 21, 2024
1 parent 02d89f1 commit 127a0fd
Show file tree
Hide file tree
Showing 65 changed files with 109 additions and 163 deletions.
24 changes: 24 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,29 @@
# Changelog

## [11.2.0](https://github.com/phun-ky/speccer/compare/v11.1.6...v11.2.0) (2024-11-21)


### Tasks

* 🤖 Upate dev file for a11y ([6ab6bc9](https://github.com/phun-ky/speccer/commit/6ab6bc9c210c0efb4114d24ecfcc90a28f75af5a))
* 🤖 Update after merge from main ([31400dc](https://github.com/phun-ky/speccer/commit/31400dc076aa1f96dfd81fbf5bc56df0e94165dc))


### Feature

* 🎸 Add and update a11y features ([29c70ba](https://github.com/phun-ky/speccer/commit/29c70ba2dda6eae3439cc9bc3aea876fea0873b2))


### Bug

* 🐛 Use correct prefix for import ([e142ffb](https://github.com/phun-ky/speccer/commit/e142ffbfe984baa4da9207a992b2accd67c76c7e))
* 🐛 Use given content to proper contain numbers ([5472419](https://github.com/phun-ky/speccer/commit/5472419137efd201e8e92a22b456c263fc58fdcf))


### Refactoring

* 💡 Adjust styling for tabstops ([d14f3c2](https://github.com/phun-ky/speccer/commit/d14f3c2accdc9cbd54f76ab3f4da16d53bc64d4b))

## [11.1.6](https://github.com/phun-ky/speccer/compare/v11.1.5...v11.1.6) (2024-11-19)


Expand Down
5 changes: 4 additions & 1 deletion api/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,17 @@

---

> Last updated 2024-11-19T19:54:48.944Z
> Last updated 2024-11-21T13:02:17.721Z
## Modules

- [config/browser](config/browser.md)
- [features/a11y](features/a11y.md)
- [features/a11y/constants](features/a11y/constants.md)
- [features/a11y/utils/add-a11y-element](features/a11y/utils/add-a11y-element.md)
- [features/a11y/utils/add-shortcut-element](features/a11y/utils/add-shortcut-element.md)
- [features/a11y/utils/create-a11y-element](features/a11y/utils/create-a11y-element.md)
- [features/a11y/utils/get-role](features/a11y/utils/get-role.md)
- [features/a11y/utils/styles](features/a11y/utils/styles.md)
- [features/grid](features/grid.md)
- [features/mark](features/mark.md)
Expand Down
10 changes: 5 additions & 5 deletions api/config/browser.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

# config/browser

> Last updated 2024-11-19T19:54:48.946Z
> Last updated 2024-11-21T13:02:17.723Z
Contains the helper functions to activate SPECCER via a script tag, based on attributes:

Expand Down Expand Up @@ -102,7 +102,7 @@ A function to activate speccer based on script attributes.

#### Defined in

[config/browser.ts:217](https://github.com/phun-ky/speccer/blob/main/src/config/browser.ts#L217)
[config/browser.ts:219](https://github.com/phun-ky/speccer/blob/main/src/config/browser.ts#L219)

---

Expand Down Expand Up @@ -133,7 +133,7 @@ A function to initialize speccer when the DOM is ready.

#### Defined in

[config/browser.ts:81](https://github.com/phun-ky/speccer/blob/main/src/config/browser.ts#L81)
[config/browser.ts:83](https://github.com/phun-ky/speccer/blob/main/src/config/browser.ts#L83)

---

Expand All @@ -158,7 +158,7 @@ A function to initialize lazy speccer functionality.

#### Defined in

[config/browser.ts:99](https://github.com/phun-ky/speccer/blob/main/src/config/browser.ts#L99)
[config/browser.ts:101](https://github.com/phun-ky/speccer/blob/main/src/config/browser.ts#L101)

---

Expand Down Expand Up @@ -189,7 +189,7 @@ A function to manually activate speccer.

#### Defined in

[config/browser.ts:202](https://github.com/phun-ky/speccer/blob/main/src/config/browser.ts#L202)
[config/browser.ts:204](https://github.com/phun-ky/speccer/blob/main/src/config/browser.ts#L204)

---

Expand Down
85 changes: 2 additions & 83 deletions api/features/a11y.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

# features/a11y

> Last updated 2024-11-19T19:54:48.950Z
> Last updated 2024-11-21T13:02:17.727Z
This feature will annotate or highlight accessibility areas like landmarks and region. It can also display tab stops/sequence and any keyboard shortcuts assigned

Expand All @@ -17,8 +17,6 @@ This feature will annotate or highlight accessibility areas like landmarks and r
- [Example](#example)
- [Functions](#functions)
- [a11y()](#a11y)
- [element()](#element)
- [shortcut()](#shortcut)

## Example

Expand Down Expand Up @@ -55,86 +53,7 @@ a11y();

#### Defined in

[features/a11y/index.ts:150](https://github.com/phun-ky/speccer/blob/main/src/features/a11y/index.ts#L150)

---

### element()

```ts
function element(targetEl, content?, type?): Promise<void>;
```

Adds an accessibility element to the document body based on the target element and type.

![Screenshot of speccer a11y tab stops in use](https://github.com/phun-ky/speccer/blob/main/public/speccer-a11y-tabstops-light.png?raw=true)
![Screenshot of speccer a11y landmark in use](https://github.com/phun-ky/speccer/blob/main/public/speccer-a11y-landmarks-light.png?raw=true)

#### Parameters

| Parameter | Type | Description |
| ---------- | ----------------------------------------------------------------------- | --------------------------------------------------------- |
| `targetEl` | [`HTMLElement`](https://developer.mozilla.org/docs/Web/API/HTMLElement) | Target HTML element. |
| `content`? | `unknown` | Content to be added to the accessibility element. |
| `type`? | `string` | Type of accessibility element ('tabstops' or 'landmark'). |

#### Returns

[`Promise`](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise)\<`void`>

A Promise resolving when the operation is complete.

#### Example

```ts
const targetElement = document.getElementById('myElement');
if (targetElement) {
await element(targetElement, 1, 'landmark');
await element(targetElement, null, 'tabstops');
}
```

#### Defined in

[features/a11y/index.ts:60](https://github.com/phun-ky/speccer/blob/main/src/features/a11y/index.ts#L60)

---

### shortcut()

```ts
function shortcut(el, shortcutString): Promise<void>;
```

Adds a shortcut element to the document body based on the provided HTML element and shortcut string.

![Screenshot of speccer a11y shortcuts in use](https://github.com/phun-ky/speccer/blob/main/public/speccer-a11y-shortcuts-light.png?raw=true)

#### Parameters

| Parameter | Type | Description |
| ---------------- | ----------------------------------------------------------------------- | -------------------------------- |
| `el` | [`HTMLElement`](https://developer.mozilla.org/docs/Web/API/HTMLElement) | Target HTML element. |
| `shortcutString` | `string` | Shortcut string to be displayed. |

#### Returns

[`Promise`](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise)\<`void`>

A Promise resolving when the operation is complete.

#### Example

```ts
const shortcutElement = document.getElementById('shortcutElement');
if (shortcutElement) {
await shortcut(shortcutElement, 'Ctrl + Shift + A');
}
```

#### Defined in

[features/a11y/index.ts:103](https://github.com/phun-ky/speccer/blob/main/src/features/a11y/index.ts#L103)
[features/a11y/index.ts:44](https://github.com/phun-ky/speccer/blob/main/src/features/a11y/index.ts#L44)

---

Expand Down
2 changes: 1 addition & 1 deletion api/features/a11y/constants.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

# features/a11y/constants

> Last updated 2024-11-19T19:54:48.951Z
> Last updated 2024-11-21T13:02:17.727Z
## Variables

Expand Down
2 changes: 1 addition & 1 deletion api/features/a11y/utils/create-a11y-element.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

# features/a11y/utils/create-a11y-element

> Last updated 2024-11-19T19:54:48.952Z
> Last updated 2024-11-21T13:02:17.730Z
## Functions

Expand Down
2 changes: 1 addition & 1 deletion api/features/a11y/utils/styles.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

# features/a11y/utils/styles

> Last updated 2024-11-19T19:54:48.953Z
> Last updated 2024-11-21T13:02:17.731Z
## Functions

Expand Down
6 changes: 3 additions & 3 deletions api/features/grid.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

# features/grid

> Last updated 2024-11-19T19:54:48.954Z
> Last updated 2024-11-21T13:02:17.732Z
This feature will highlight the grid spacing in a `display: grid;` element.

Expand Down Expand Up @@ -73,7 +73,7 @@ if (targetElement) {

#### Defined in

[features/grid/index.ts:61](https://github.com/phun-ky/speccer/blob/main/src/features/grid/index.ts#L61)
[features/grid/index.ts:63](https://github.com/phun-ky/speccer/blob/main/src/features/grid/index.ts#L63)

---

Expand Down Expand Up @@ -128,7 +128,7 @@ grid(targetElement, options);

#### Defined in

[features/grid/index.ts:202](https://github.com/phun-ky/speccer/blob/main/src/features/grid/index.ts#L202)
[features/grid/index.ts:204](https://github.com/phun-ky/speccer/blob/main/src/features/grid/index.ts#L204)

---

Expand Down
6 changes: 3 additions & 3 deletions api/features/mark.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

# features/mark

> Last updated 2024-11-19T19:54:48.955Z
> Last updated 2024-11-21T13:02:17.733Z
This feature marks given element

Expand Down Expand Up @@ -68,7 +68,7 @@ document.body.appendChild(marker);

#### Defined in

[features/mark/index.ts:53](https://github.com/phun-ky/speccer/blob/main/src/features/mark/index.ts#L53)
[features/mark/index.ts:55](https://github.com/phun-ky/speccer/blob/main/src/features/mark/index.ts#L55)

---

Expand Down Expand Up @@ -103,7 +103,7 @@ mark(targetElement);

#### Defined in

[features/mark/index.ts:77](https://github.com/phun-ky/speccer/blob/main/src/features/mark/index.ts#L77)
[features/mark/index.ts:79](https://github.com/phun-ky/speccer/blob/main/src/features/mark/index.ts#L79)

---

Expand Down
6 changes: 3 additions & 3 deletions api/features/measure.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

# features/measure

> Last updated 2024-11-19T19:54:48.955Z
> Last updated 2024-11-21T13:02:17.733Z
This feature measures given element

Expand Down Expand Up @@ -78,7 +78,7 @@ document.body.appendChild(measurement);

#### Defined in

[features/measure/index.ts:59](https://github.com/phun-ky/speccer/blob/main/src/features/measure/index.ts#L59)
[features/measure/index.ts:61](https://github.com/phun-ky/speccer/blob/main/src/features/measure/index.ts#L61)

---

Expand Down Expand Up @@ -140,7 +140,7 @@ measure(targetElement, options);

#### Defined in

[features/measure/index.ts:125](https://github.com/phun-ky/speccer/blob/main/src/features/measure/index.ts#L125)
[features/measure/index.ts:127](https://github.com/phun-ky/speccer/blob/main/src/features/measure/index.ts#L127)

---

Expand Down
4 changes: 2 additions & 2 deletions api/features/pin.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

# features/pin

> Last updated 2024-11-19T19:54:48.956Z
> Last updated 2024-11-21T13:02:17.734Z
This feature annotate or highlight the anatomy of an element.

Expand Down Expand Up @@ -76,7 +76,7 @@ pinElements(sectionElement);

#### Defined in

[features/pin/index.ts:49](https://github.com/phun-ky/speccer/blob/main/src/features/pin/index.ts#L49)
[features/pin/index.ts:51](https://github.com/phun-ky/speccer/blob/main/src/features/pin/index.ts#L51)

---

Expand Down
2 changes: 1 addition & 1 deletion api/features/pin/utils/create-pin-element.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

# features/pin/utils/create-pin-element

> Last updated 2024-11-19T19:54:48.957Z
> Last updated 2024-11-21T13:02:17.735Z
## Functions

Expand Down
2 changes: 1 addition & 1 deletion api/features/pin/utils/get-character-to-use.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

# features/pin/utils/get-character-to-use

> Last updated 2024-11-19T19:54:48.957Z
> Last updated 2024-11-21T13:02:17.735Z
## Functions

Expand Down
2 changes: 1 addition & 1 deletion api/features/pin/utils/get-content-for-pin.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

# features/pin/utils/get-content-for-pin

> Last updated 2024-11-19T19:54:48.958Z
> Last updated 2024-11-21T13:02:17.735Z
## Functions

Expand Down
2 changes: 1 addition & 1 deletion api/features/pin/utils/pin-element.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

# features/pin/utils/pin-element

> Last updated 2024-11-19T19:54:48.958Z
> Last updated 2024-11-21T13:02:17.736Z
## Functions

Expand Down
2 changes: 1 addition & 1 deletion api/features/pin/utils/styles.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

# features/pin/utils/styles

> Last updated 2024-11-19T19:54:48.958Z
> Last updated 2024-11-21T13:02:17.736Z
## Functions

Expand Down
6 changes: 3 additions & 3 deletions api/features/spacing.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

# features/spacing

> Last updated 2024-11-19T19:54:48.958Z
> Last updated 2024-11-21T13:02:17.736Z
This feature highlights the spacing of an element.

Expand Down Expand Up @@ -64,7 +64,7 @@ document.body.appendChild(spacingElement);

#### Defined in

[features/spacing/index.ts:52](https://github.com/phun-ky/speccer/blob/main/src/features/spacing/index.ts#L52)
[features/spacing/index.ts:54](https://github.com/phun-ky/speccer/blob/main/src/features/spacing/index.ts#L54)

---

Expand Down Expand Up @@ -131,7 +131,7 @@ element(targetElement, options);
#### Defined in
[features/spacing/index.ts:113](https://github.com/phun-ky/speccer/blob/main/src/features/spacing/index.ts#L113)
[features/spacing/index.ts:115](https://github.com/phun-ky/speccer/blob/main/src/features/spacing/index.ts#L115)
---
Expand Down
Loading

0 comments on commit 127a0fd

Please sign in to comment.