jekyll-webawesome 0.20.0 → 0.22.0

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 357c6fd1272603627457c36d096cd9df2eafefc0fbe79564278d246db85ee400
4
- data.tar.gz: 55058f53d7164006a4de03d8135245b957cc88b3ff6562339dccc67bac2e5690
3
+ metadata.gz: a1cb8eddf8f4d4315a3830f3cf5703a487418ea02cd56d24763f19dd82713aa6
4
+ data.tar.gz: 479e8f0e52929d625f2e3de1120ccc692c573b041c3c1e4072add1b0ad4086ae
5
5
  SHA512:
6
- metadata.gz: 17840e18f7bc1c5c131a30320b05ea243a5215519aa46dff76c55ab6b9abc06959751acae7c98504d71f62a0b2dd8ac97100f9eed9aed3bc72ce76546370a10a
7
- data.tar.gz: fe51782529d4091b9675dd074c88e2ce568e98e955190a1ef47c0eea3105f8ef08eceff4d0ce22f0b75740347df3ce31d813df0f36ec45e78938ec6bdb74418e
6
+ metadata.gz: 1d7a953b33ab397050e35fc8086515e32d5c1a2e23cc3a0731e5c9971bc9bca37ad489df671cb565442df43127f24b0c5486ae32dc97707f4d27b5745b83ef23
7
+ data.tar.gz: 8e74b834dc51e1f2129463cd53eca8eb578faaa1c35d82dc8bdd282efcbd866d5bbe7a95db77423ef5ab5e7519872bd9b264e15f1e48d084e13eaab3ac180db9
data/CHANGELOG.md CHANGED
@@ -4,6 +4,24 @@ All notable changes to this project will be documented in this file.
4
4
 
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/)
6
6
 
7
+ ## [0.22.0] - 2026-06-25
8
+
9
+ ### Added
10
+
11
+ - Copy-button tooltip mode, via markawesome 0.16.0. A `tooltip:full|copy|none` token on the copy-button line controls *when* the built-in tooltip appears, distinct from the existing `tooltip-placement`: `full` (Web Awesome's default — tooltip on hover/focus plus the brief copy-success/error feedback), `copy` (silent on hover/focus; the tooltip appears only to confirm a copy), and `none` (no tooltip in any state). Combine it with a placement, e.g. `<<<top tooltip:copy`. The token is order-independent with the other copy-button parameters; invalid values are dropped and fall back to Web Awesome's default.
12
+ - Example site's `## Copy Buttons` section gains a `### Tooltip Mode` subsection exercising `full`, `copy`, `none`, and a placement combination (`<<<top tooltip:copy`). Validated live in the browser against the examples kit (WA 3.9.0, ≥ 3.6 so `tooltip` is supported): the `tooltip` attribute reflects onto the upgraded `<wa-copy-button>`, and the rendered behavior differs as expected — `full` builds an internal `<wa-tooltip trigger="hover focus">` (opens on hover/focus, shown opening on hover in the live DOM), `copy` builds `<wa-tooltip trigger="manual">` (silent on hover/focus, copy-feedback only), `none` renders no internal tooltip at all (none on hover, confirmed live), and `<<<top tooltip:copy` carries both `tooltip-placement="top"` and `tooltip="copy"`.
13
+
14
+ ### Changed
15
+
16
+ - Updated `markawesome` dependency to `~> 0.16`.
17
+
18
+ ## [0.21.0] - 2026-06-25
19
+
20
+ ### Added
21
+
22
+ - Tooltip support, via markawesome 0.15.0. Inline contextual help shown on hover or focus — ideal for glossary terms and inline definitions. The primary form is inline: `(((anchor term >>> tip text)))`. The anchor becomes a focusable, dotted-underlined `<span>` (`tabindex="0"`, class `ma-tooltip-anchor`) and the tip is emitted as a `<wa-tooltip>` wired to it via a generated `for`/`id` pair, so keyboard and assistive-technology users get the tip too. Leading `placement` (`top` default, `bottom`, `left`, `right`) and `distance:N` tokens go before the anchor; tip text is plain text (HTML-escaped) with literal `\n` rendered as `<br>`. A `:::wa-tooltip placement? distance:N? … >>> … :::` block alternative is also accepted. Declarative and zero-JavaScript; no Jekyll-side configuration needed.
23
+ - Example site gains a `## Tooltips` section exercising the basic inline form, every placement, `distance:N`, combined parameters, multiple inline tooltips in one sentence, HTML escaping, `\n` line breaks, and the `:::wa-tooltip` alternative form. Validated live in the browser against the examples kit (WA 3.9.0): each anchor's `for` resolves to its tooltip's `id`, the `<wa-tooltip>` upgrades and opens on both hover and focus, and the requested `placement` positions the bubble correctly in the live DOM.
24
+
7
25
  ## [0.20.0] - 2026-06-24
8
26
 
9
27
  ### Added
data/README.md CHANGED
@@ -20,13 +20,14 @@ This plugin focuses on the most commonly used Web Awesome components for Jekyll
20
20
  | **Card** | `===appearance? orientation?` | `:::wa-card appearance? orientation?` | `<wa-card appearance="filled" orientation="horizontal">content</wa-card>` |
21
21
  | **Carousel** | `~~~~~~` | `:::wa-carousel` | `<wa-carousel>` with carousel items |
22
22
  | **Comparison** | `\|\|\|` or `\|\|\|25` | `:::wa-comparison` or `:::wa-comparison 25` | `<wa-comparison>` with before/after slots |
23
- | **Copy Button** | `<<<placement? disabled? duration? labels?` | `:::wa-copy-button attributes?` | `<wa-copy-button value="content" tooltip-placement="right" disabled>` |
23
+ | **Copy Button** | `<<<placement? tooltip:mode? disabled? duration? labels?` | `:::wa-copy-button attributes?` | `<wa-copy-button value="content" tooltip-placement="right" tooltip="copy" disabled>` |
24
24
  | **Details** | `^^^appearance? icon-placement?` | `:::wa-details appearance? icon-placement?` | `<wa-details appearance="..." icon-placement="...">content</wa-details>` |
25
25
  | **Dialog** | `???params?` | `:::wa-dialog params?` | `<wa-dialog>` with trigger button and content |
26
26
  | **Icon** | `$$$icon-name` | `:::wa-icon name` | `<wa-icon name="icon-name" variant="solid"></wa-icon>` |
27
27
  | **Popover** | `&&&placement? link? without-arrow? distance:N?` | `:::wa-popover params?` | `<wa-popover>` with trigger and floating content |
28
28
  | **Tab Group** | `++++++` | `:::wa-tabs` | `<wa-tab-group><wa-tab>content</wa-tab></wa-tab-group>` |
29
29
  | **Tag** | `@@@brand` | `:::wa-tag brand` | `<wa-tag variant="brand">content</wa-tag>` |
30
+ | **Tooltip** | `(((anchor >>> tip)))` | `:::wa-tooltip placement? distance:N?` | focusable `<span>` anchor + `<wa-tooltip for="…" placement="top">tip</wa-tooltip>` |
30
31
 
31
32
  Not all components will make sense to include here, to be included in the "prose" content of a web page. Some components are more suitable to be used in layouts or used in the page as includes, too complicated for this purpose.
32
33
 
@@ -721,6 +722,27 @@ Copy with tooltip on left
721
722
  <<<
722
723
  ```
723
724
 
725
+ **Tooltip Mode:**
726
+
727
+ Control *when* the built-in tooltip appears (`full`, `copy`, or `none`):
728
+ ```markdown
729
+ <<<tooltip:full
730
+ Full (default): tooltip on hover/focus plus copy feedback
731
+ <<<
732
+
733
+ <<<tooltip:copy
734
+ Copy: silent on hover/focus; tooltip only on copy feedback
735
+ <<<
736
+
737
+ <<<tooltip:none
738
+ None: no tooltip in any state
739
+ <<<
740
+
741
+ <<<top tooltip:copy
742
+ Combined with a tooltip placement
743
+ <<<
744
+ ```
745
+
724
746
  **Custom Labels:**
725
747
  ```markdown
726
748
  <<<copy-label="Click to copy" success-label="Copied!" error-label="Failed"
@@ -1215,6 +1237,82 @@ Popover content using the alternative syntax.
1215
1237
  | `without-arrow` | keyword | off | Hides the popover arrow |
1216
1238
  | `distance:N` | number (pixels) | (default) | Distance between trigger and popover |
1217
1239
 
1240
+ ### Tooltips
1241
+
1242
+ Add brief contextual help on hover or focus — ideal for glossary terms and inline definitions. The primary form is inline: put the anchor term and the tip text inside triple parentheses, separated by `>>>`:
1243
+
1244
+ ```markdown
1245
+ The web is styled with (((CSS >>> Cascading Style Sheets))) and structured with (((HTML >>> HyperText Markup Language))).
1246
+ ```
1247
+
1248
+ The anchor term becomes a focusable, dotted-underlined `<span>`, with a `<wa-tooltip>` wired to it via a generated `for`/`id` pair:
1249
+
1250
+ ```html
1251
+ <span id="tooltip-ab12c3d4" tabindex="0" class="ma-tooltip-anchor" style="text-decoration: underline dotted; cursor: help;">CSS</span>
1252
+ <wa-tooltip for="tooltip-ab12c3d4" placement="top">Cascading Style Sheets</wa-tooltip>
1253
+ ```
1254
+
1255
+ The anchor is focusable (`tabindex="0"`) so keyboard and assistive-technology users get the tip too (Web Awesome tooltips fire on focus as well as hover). The `ma-tooltip-anchor` class is a styling hook for overriding the default underline/cursor. No JavaScript is required.
1256
+
1257
+ #### Tooltip Placement
1258
+
1259
+ Leading `placement`/`distance:N` tokens go before the anchor term:
1260
+
1261
+ ```markdown
1262
+ Routed over (((bottom Peppol >>> A standardized pan-European e-invoicing network))) to the recipient.
1263
+
1264
+ Authentication uses an (((left API key >>> A secret token that authorizes a request))).
1265
+
1266
+ Files are delivered over (((right SFTP >>> SSH File Transfer Protocol))) for batch processing.
1267
+ ```
1268
+
1269
+ **Supported placements:** `top` (default), `bottom`, `left`, `right`
1270
+
1271
+ #### Custom Distance
1272
+
1273
+ Set the distance between the anchor and the tooltip (in pixels):
1274
+
1275
+ ```markdown
1276
+ Hover over (((distance:12 SLA >>> Service Level Agreement))) to see the tip pushed further from the anchor.
1277
+ ```
1278
+
1279
+ #### Combining Parameters
1280
+
1281
+ Tokens can be combined in any order before the anchor term:
1282
+
1283
+ ```markdown
1284
+ Read about (((bottom distance:8 OCR >>> Optical Character Recognition))) in the pipeline.
1285
+ ```
1286
+
1287
+ #### Tip Content and Line Breaks
1288
+
1289
+ Tip text is plain text and HTML-escaped, so symbols are safe. Use `\n` for line breaks (rendered as `<br>`):
1290
+
1291
+ ```markdown
1292
+ Org numbers differ by country — (((Org number >>> NO: 9 digits\nSE: 10 digits\nDK: 8-digit CVR))).
1293
+ ```
1294
+
1295
+ Tooltips hold brief text, so there is no Markdown body (unlike popovers).
1296
+
1297
+ #### Alternative Syntax
1298
+
1299
+ For consistency with the other components, a block form is also accepted:
1300
+
1301
+ ```markdown
1302
+ :::wa-tooltip bottom
1303
+ JIT
1304
+ >>>
1305
+ Just-In-Time — produced only at the moment it is needed.
1306
+ :::
1307
+ ```
1308
+
1309
+ #### Tooltip Parameters
1310
+
1311
+ | Option | Values | Default | Description |
1312
+ |--------|--------|---------|-------------|
1313
+ | `placement` | `top`, `bottom`, `left`, `right` | `top` | Where the tooltip appears relative to the anchor |
1314
+ | `distance:N` | number (pixels) | (default) | Distance between the anchor and the tooltip |
1315
+
1218
1316
  ### Details/Summary (Collapsible Content)
1219
1317
 
1220
1318
  Create collapsible content using the `^^^` syntax:
@@ -33,7 +33,7 @@ Gem::Specification.new do |spec|
33
33
  spec.require_paths = ['lib']
34
34
 
35
35
  spec.add_dependency 'jekyll', '>= 3.7', '< 5.0'
36
- spec.add_dependency 'markawesome', '~> 0.14'
36
+ spec.add_dependency 'markawesome', '~> 0.16'
37
37
 
38
38
  spec.add_development_dependency 'rake', '~> 13.0'
39
39
  spec.add_development_dependency 'rspec', '~> 3.0'
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Jekyll
4
4
  module WebAwesome
5
- VERSION = '0.20.0'
5
+ VERSION = '0.22.0'
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jekyll-webawesome
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.20.0
4
+ version: 0.22.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Janne Waren
@@ -35,14 +35,14 @@ dependencies:
35
35
  requirements:
36
36
  - - "~>"
37
37
  - !ruby/object:Gem::Version
38
- version: '0.14'
38
+ version: '0.16'
39
39
  type: :runtime
40
40
  prerelease: false
41
41
  version_requirements: !ruby/object:Gem::Requirement
42
42
  requirements:
43
43
  - - "~>"
44
44
  - !ruby/object:Gem::Version
45
- version: '0.14'
45
+ version: '0.16'
46
46
  - !ruby/object:Gem::Dependency
47
47
  name: rake
48
48
  requirement: !ruby/object:Gem::Requirement