@warp-ds/elements 2.9.0-next.6 → 2.9.1-next.1

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.
Files changed (40) hide show
  1. package/dist/custom-elements.json +80 -21
  2. package/dist/docs/affix/affix.md +24 -38
  3. package/dist/docs/affix/examples.md +24 -38
  4. package/dist/docs/alert/accessibility.md +4 -9
  5. package/dist/docs/alert/alert.md +24 -39
  6. package/dist/docs/alert/examples.md +20 -30
  7. package/dist/docs/attention/accessibility.md +50 -0
  8. package/dist/docs/attention/api.md +40 -27
  9. package/dist/docs/attention/attention.md +276 -27
  10. package/dist/docs/attention/examples.md +91 -0
  11. package/dist/docs/attention/usage.md +91 -0
  12. package/dist/docs/badge/badge.md +23 -36
  13. package/dist/docs/badge/examples.md +23 -36
  14. package/dist/docs/box/accessibility.md +29 -0
  15. package/dist/docs/box/api.md +16 -11
  16. package/dist/docs/box/box.md +189 -11
  17. package/dist/docs/box/examples.md +98 -0
  18. package/dist/docs/box/usage.md +47 -0
  19. package/dist/docs/textarea/accessibility.md +5 -0
  20. package/dist/docs/textarea/api.md +32 -47
  21. package/dist/docs/textarea/examples.md +81 -0
  22. package/dist/docs/textarea/textarea.md +133 -49
  23. package/dist/docs/textarea/usage.md +9 -0
  24. package/dist/docs/textfield/examples.md +32 -49
  25. package/dist/docs/textfield/textfield.md +39 -60
  26. package/dist/docs/textfield/usage.md +7 -11
  27. package/dist/index.d.ts +276 -154
  28. package/dist/packages/attention/attention.d.ts +46 -37
  29. package/dist/packages/attention/attention.js +20 -20
  30. package/dist/packages/attention/attention.js.map +3 -3
  31. package/dist/packages/box/box.d.ts +15 -14
  32. package/dist/packages/box/box.js +6 -6
  33. package/dist/packages/box/box.js.map +4 -4
  34. package/dist/packages/box/box.react.stories.d.ts +1 -1
  35. package/dist/packages/box/box.stories.d.ts +1 -0
  36. package/dist/packages/box/box.stories.js +12 -5
  37. package/dist/packages/textarea/textarea.d.ts +38 -29
  38. package/dist/packages/textarea/textarea.js.map +2 -2
  39. package/dist/web-types.json +216 -44
  40. package/package.json +1 -2
@@ -1469,7 +1469,7 @@
1469
1469
  "declarations": [
1470
1470
  {
1471
1471
  "kind": "class",
1472
- "description": "",
1472
+ "description": "Attention is a versatile component for displaying contextual information and messages. It can be used for a wide range of purposes, such as tooltips, callouts, popovers, and highlights.\n\nThe component is designed to be anchored to a trigger element, providing contextual information related to that element. It supports various placements and styling options to accommodate different use cases and design needs.\n\nNote: attention will soon be split into multiple components (tooltip, callout, popover, highlight) at which time this component will be deprecated. For now, use the `tooltip`, `callout`, `popover`, and `highlight` boolean properties to achieve the desired style and behavior.",
1473
1473
  "name": "WarpAttention",
1474
1474
  "members": [
1475
1475
  {
@@ -1479,6 +1479,7 @@
1479
1479
  "text": "boolean"
1480
1480
  },
1481
1481
  "default": "false",
1482
+ "description": "Controls whether the attention panel is visible.\nSet to `true` to show the attention content and `false` to hide it.",
1482
1483
  "attribute": "show",
1483
1484
  "reflects": true
1484
1485
  },
@@ -1488,6 +1489,7 @@
1488
1489
  "type": {
1489
1490
  "text": "Directions"
1490
1491
  },
1492
+ "description": "Preferred placement relative to the trigger element.\nSets the initial direction for positioning, for example `top`, `right`, `bottom`, or `left` variants.",
1491
1493
  "default": "'bottom'",
1492
1494
  "attribute": "placement"
1493
1495
  },
@@ -1498,6 +1500,7 @@
1498
1500
  "text": "boolean"
1499
1501
  },
1500
1502
  "default": "false",
1503
+ "description": "Renders the component with tooltip styling and behavior.\nUse for compact, non-modal contextual hints anchored to another element.",
1501
1504
  "attribute": "tooltip",
1502
1505
  "reflects": true
1503
1506
  },
@@ -1508,6 +1511,7 @@
1508
1511
  "text": "boolean"
1509
1512
  },
1510
1513
  "default": "false",
1514
+ "description": "Renders the component as an inline callout.\nCallout mode is used for always-in-flow informational content instead of floating overlay behavior.",
1511
1515
  "attribute": "callout",
1512
1516
  "reflects": true
1513
1517
  },
@@ -1517,6 +1521,7 @@
1517
1521
  "type": {
1518
1522
  "text": "boolean"
1519
1523
  },
1524
+ "description": "Enables native popover behavior for the attention element.\nWhen enabled, the component uses popover semantics and styling suitable for floating surface UI.",
1520
1525
  "default": "false",
1521
1526
  "attribute": "popover",
1522
1527
  "reflects": true
@@ -1528,6 +1533,7 @@
1528
1533
  "text": "boolean"
1529
1534
  },
1530
1535
  "default": "false",
1536
+ "description": "Renders the component with highlight styling.\nUse highlight mode to visually emphasize important contextual information.",
1531
1537
  "attribute": "highlight",
1532
1538
  "reflects": true
1533
1539
  },
@@ -1538,6 +1544,7 @@
1538
1544
  "text": "boolean"
1539
1545
  },
1540
1546
  "default": "false",
1547
+ "description": "Shows a close button inside the attention component.\nAdds an internal dismiss action that lets users close the attention panel.",
1541
1548
  "attribute": "can-close",
1542
1549
  "reflects": true
1543
1550
  },
@@ -1548,6 +1555,7 @@
1548
1555
  "text": "boolean"
1549
1556
  },
1550
1557
  "default": "false",
1558
+ "description": "Hides the directional arrow of the attention component.\nDisable the arrow when the visual connection to the trigger should not be shown.",
1551
1559
  "attribute": "no-arrow",
1552
1560
  "reflects": true
1553
1561
  },
@@ -1557,6 +1565,7 @@
1557
1565
  "type": {
1558
1566
  "text": "number"
1559
1567
  },
1568
+ "description": "Distance offset between trigger and attention panel.\nDefines the main-axis spacing in pixels from the anchor element.",
1560
1569
  "default": "8",
1561
1570
  "attribute": "distance"
1562
1571
  },
@@ -1566,6 +1575,7 @@
1566
1575
  "type": {
1567
1576
  "text": "number"
1568
1577
  },
1578
+ "description": "Cross-axis offset for fine-grained positioning.\nMoves the panel along the cross axis in pixels to adjust alignment with the trigger.",
1569
1579
  "default": "0",
1570
1580
  "attribute": "skidding"
1571
1581
  },
@@ -1576,6 +1586,7 @@
1576
1586
  "text": "boolean"
1577
1587
  },
1578
1588
  "default": "false",
1589
+ "description": "Enables automatic flipping when placement has no space.\nAllows the component to choose an alternative side if the preferred placement would overflow.",
1579
1590
  "attribute": "flip",
1580
1591
  "reflects": true
1581
1592
  },
@@ -1586,6 +1597,7 @@
1586
1597
  "text": "boolean"
1587
1598
  },
1588
1599
  "default": "false",
1600
+ "description": "Allows overflow checks on the cross axis when flipping.\nUse with `flip` to improve collision handling when space is constrained horizontally or vertically.",
1589
1601
  "attribute": "cross-axis",
1590
1602
  "reflects": true
1591
1603
  },
@@ -1595,6 +1607,8 @@
1595
1607
  "type": {
1596
1608
  "text": "Directions[]"
1597
1609
  },
1610
+ "default": "[]",
1611
+ "description": "Ordered list of fallback placements.\nProvides explicit alternative placements to try when `flip` is enabled and the preferred placement does not fit.",
1598
1612
  "attribute": "fallback-placements",
1599
1613
  "reflects": true
1600
1614
  },
@@ -1664,6 +1678,7 @@
1664
1678
  "text": "boolean"
1665
1679
  },
1666
1680
  "default": "false",
1681
+ "description": "Controls whether the attention panel is visible.\nSet to `true` to show the attention content and `false` to hide it.",
1667
1682
  "fieldName": "show"
1668
1683
  },
1669
1684
  {
@@ -1671,6 +1686,7 @@
1671
1686
  "type": {
1672
1687
  "text": "Directions"
1673
1688
  },
1689
+ "description": "Preferred placement relative to the trigger element.\nSets the initial direction for positioning, for example `top`, `right`, `bottom`, or `left` variants.",
1674
1690
  "default": "'bottom'",
1675
1691
  "fieldName": "placement"
1676
1692
  },
@@ -1680,6 +1696,7 @@
1680
1696
  "text": "boolean"
1681
1697
  },
1682
1698
  "default": "false",
1699
+ "description": "Renders the component with tooltip styling and behavior.\nUse for compact, non-modal contextual hints anchored to another element.",
1683
1700
  "fieldName": "tooltip"
1684
1701
  },
1685
1702
  {
@@ -1688,6 +1705,7 @@
1688
1705
  "text": "boolean"
1689
1706
  },
1690
1707
  "default": "false",
1708
+ "description": "Renders the component as an inline callout.\nCallout mode is used for always-in-flow informational content instead of floating overlay behavior.",
1691
1709
  "fieldName": "callout"
1692
1710
  },
1693
1711
  {
@@ -1695,6 +1713,7 @@
1695
1713
  "type": {
1696
1714
  "text": "boolean"
1697
1715
  },
1716
+ "description": "Enables native popover behavior for the attention element.\nWhen enabled, the component uses popover semantics and styling suitable for floating surface UI.",
1698
1717
  "default": "false",
1699
1718
  "fieldName": "popover"
1700
1719
  },
@@ -1704,6 +1723,7 @@
1704
1723
  "text": "boolean"
1705
1724
  },
1706
1725
  "default": "false",
1726
+ "description": "Renders the component with highlight styling.\nUse highlight mode to visually emphasize important contextual information.",
1707
1727
  "fieldName": "highlight"
1708
1728
  },
1709
1729
  {
@@ -1712,6 +1732,7 @@
1712
1732
  "text": "boolean"
1713
1733
  },
1714
1734
  "default": "false",
1735
+ "description": "Shows a close button inside the attention component.\nAdds an internal dismiss action that lets users close the attention panel.",
1715
1736
  "fieldName": "canClose"
1716
1737
  },
1717
1738
  {
@@ -1720,6 +1741,7 @@
1720
1741
  "text": "boolean"
1721
1742
  },
1722
1743
  "default": "false",
1744
+ "description": "Hides the directional arrow of the attention component.\nDisable the arrow when the visual connection to the trigger should not be shown.",
1723
1745
  "fieldName": "noArrow"
1724
1746
  },
1725
1747
  {
@@ -1727,6 +1749,7 @@
1727
1749
  "type": {
1728
1750
  "text": "number"
1729
1751
  },
1752
+ "description": "Distance offset between trigger and attention panel.\nDefines the main-axis spacing in pixels from the anchor element.",
1730
1753
  "default": "8",
1731
1754
  "fieldName": "distance"
1732
1755
  },
@@ -1735,6 +1758,7 @@
1735
1758
  "type": {
1736
1759
  "text": "number"
1737
1760
  },
1761
+ "description": "Cross-axis offset for fine-grained positioning.\nMoves the panel along the cross axis in pixels to adjust alignment with the trigger.",
1738
1762
  "default": "0",
1739
1763
  "fieldName": "skidding"
1740
1764
  },
@@ -1744,6 +1768,7 @@
1744
1768
  "text": "boolean"
1745
1769
  },
1746
1770
  "default": "false",
1771
+ "description": "Enables automatic flipping when placement has no space.\nAllows the component to choose an alternative side if the preferred placement would overflow.",
1747
1772
  "fieldName": "flip"
1748
1773
  },
1749
1774
  {
@@ -1752,6 +1777,7 @@
1752
1777
  "text": "boolean"
1753
1778
  },
1754
1779
  "default": "false",
1780
+ "description": "Allows overflow checks on the cross axis when flipping.\nUse with `flip` to improve collision handling when space is constrained horizontally or vertically.",
1755
1781
  "fieldName": "crossAxis"
1756
1782
  },
1757
1783
  {
@@ -1759,6 +1785,8 @@
1759
1785
  "type": {
1760
1786
  "text": "Directions[]"
1761
1787
  },
1788
+ "default": "[]",
1789
+ "description": "Ordered list of fallback placements.\nProvides explicit alternative placements to try when `flip` is enabled and the preferred placement does not fit.",
1762
1790
  "fieldName": "fallbackPlacements"
1763
1791
  }
1764
1792
  ],
@@ -1890,6 +1918,7 @@
1890
1918
  "text": "boolean"
1891
1919
  },
1892
1920
  "default": "false",
1921
+ "description": "Makes the box bleed to the container edge.\nExtends the box into the horizontal gutter on narrow screens. Adds negative horizontal margins and square side corners below the small breakpoint, then restores the normal margins and rounded corners from the small breakpoint and up.",
1893
1922
  "attribute": "bleed",
1894
1923
  "reflects": true
1895
1924
  },
@@ -1900,6 +1929,7 @@
1900
1929
  "text": "boolean"
1901
1930
  },
1902
1931
  "default": "false",
1932
+ "description": "Shows the box as a bordered surface.\nUse this when the content needs a clear visual boundary from the surrounding page.",
1903
1933
  "attribute": "bordered",
1904
1934
  "reflects": true
1905
1935
  },
@@ -1910,6 +1940,7 @@
1910
1940
  "text": "boolean"
1911
1941
  },
1912
1942
  "default": "false",
1943
+ "description": "Shows the box with information styling.\nUse this for supporting informational content that should be visually separated from the surrounding page.",
1913
1944
  "attribute": "info",
1914
1945
  "reflects": true
1915
1946
  },
@@ -1920,6 +1951,7 @@
1920
1951
  "text": "boolean"
1921
1952
  },
1922
1953
  "default": "false",
1954
+ "description": "Shows the box with neutral styling.\nUse this for quiet grouped content that needs a background without strong emphasis.",
1923
1955
  "attribute": "neutral",
1924
1956
  "reflects": true
1925
1957
  },
@@ -1929,6 +1961,8 @@
1929
1961
  "type": {
1930
1962
  "text": "string"
1931
1963
  },
1964
+ "default": "'region'",
1965
+ "description": "ARIA role for the box wrapper.\nDefaults to a role of `region`. Set `role=\"none\"` to override this behaviour for purely visual grouping, or set a specific role when the box has a clearer semantic purpose.",
1932
1966
  "attribute": "role",
1933
1967
  "reflects": true
1934
1968
  }
@@ -1940,6 +1974,7 @@
1940
1974
  "text": "boolean"
1941
1975
  },
1942
1976
  "default": "false",
1977
+ "description": "Makes the box bleed to the container edge.\nExtends the box into the horizontal gutter on narrow screens. Adds negative horizontal margins and square side corners below the small breakpoint, then restores the normal margins and rounded corners from the small breakpoint and up.",
1943
1978
  "fieldName": "bleed"
1944
1979
  },
1945
1980
  {
@@ -1948,6 +1983,7 @@
1948
1983
  "text": "boolean"
1949
1984
  },
1950
1985
  "default": "false",
1986
+ "description": "Shows the box as a bordered surface.\nUse this when the content needs a clear visual boundary from the surrounding page.",
1951
1987
  "fieldName": "bordered"
1952
1988
  },
1953
1989
  {
@@ -1956,6 +1992,7 @@
1956
1992
  "text": "boolean"
1957
1993
  },
1958
1994
  "default": "false",
1995
+ "description": "Shows the box with information styling.\nUse this for supporting informational content that should be visually separated from the surrounding page.",
1959
1996
  "fieldName": "info"
1960
1997
  },
1961
1998
  {
@@ -1964,6 +2001,7 @@
1964
2001
  "text": "boolean"
1965
2002
  },
1966
2003
  "default": "false",
2004
+ "description": "Shows the box with neutral styling.\nUse this for quiet grouped content that needs a background without strong emphasis.",
1967
2005
  "fieldName": "neutral"
1968
2006
  },
1969
2007
  {
@@ -1971,9 +2009,17 @@
1971
2009
  "type": {
1972
2010
  "text": "string"
1973
2011
  },
2012
+ "default": "'region'",
2013
+ "description": "ARIA role for the box wrapper.\nDefaults to a role of `region`. Set `role=\"none\"` to override this behaviour for purely visual grouping, or set a specific role when the box has a clearer semantic purpose.",
1974
2014
  "fieldName": "role"
1975
2015
  }
1976
2016
  ],
2017
+ "mixins": [
2018
+ {
2019
+ "name": "FormControlMixin",
2020
+ "package": "@open-wc/form-control"
2021
+ }
2022
+ ],
1977
2023
  "superclass": {
1978
2024
  "name": "LitElement",
1979
2025
  "package": "lit"
@@ -8048,18 +8094,9 @@
8048
8094
  "declarations": [
8049
8095
  {
8050
8096
  "kind": "class",
8051
- "description": "A single line text input element.\n\n[See Storybook for usage examples](https://warp-ds.github.io/elements/?path=/docs/forms-textfield--docs)",
8097
+ "description": "A multi-line text input with built-in form validation, auto-resizing, and styling support.\n\nThe component automatically handles:\n - Form integration\n - Auto-resizing based on content and row constraints\n - Built-in validation with customizable error messages\n - Accessibility attributes and labeling",
8052
8098
  "name": "WarpTextarea",
8053
8099
  "members": [
8054
- {
8055
- "kind": "field",
8056
- "name": "shadowRootOptions",
8057
- "type": {
8058
- "text": "object"
8059
- },
8060
- "static": true,
8061
- "default": "{ ...LitElement.shadowRootOptions, delegatesFocus: true, }"
8062
- },
8063
8100
  {
8064
8101
  "kind": "field",
8065
8102
  "name": "disabled",
@@ -8067,6 +8104,8 @@
8067
8104
  "text": "boolean"
8068
8105
  },
8069
8106
  "default": "false",
8107
+ "description": "Keep in mind that using disabled in its current form is an anti-pattern.\n\nThere will always be users who don't understand why an element is disabled, or users who can't even see that it is disabled because of poor lighting conditions or other reasons.\n\nPlease consider more informative alternatives before choosing to use disabled on an element.",
8108
+ "summary": "Makes the element not focusable and hides it from form submits",
8070
8109
  "attribute": "disabled",
8071
8110
  "reflects": true
8072
8111
  },
@@ -8077,6 +8116,7 @@
8077
8116
  "text": "boolean"
8078
8117
  },
8079
8118
  "default": "false",
8119
+ "description": "Mark the form field as invalid.\n\nMake sure to also set a `help-text` to help users fix the validation problem.",
8080
8120
  "attribute": "invalid",
8081
8121
  "reflects": true
8082
8122
  },
@@ -8086,6 +8126,7 @@
8086
8126
  "type": {
8087
8127
  "text": "string"
8088
8128
  },
8129
+ "description": "Either a `label` or an `aria-label` must be provided.",
8089
8130
  "attribute": "label",
8090
8131
  "reflects": true
8091
8132
  },
@@ -8095,6 +8136,8 @@
8095
8136
  "type": {
8096
8137
  "text": "string"
8097
8138
  },
8139
+ "description": "Use in combination with `invalid` to show as a validation error message,\nor on its own to show a help text.",
8140
+ "summary": "Description shown below the input field",
8098
8141
  "attribute": "help-text",
8099
8142
  "reflects": true
8100
8143
  },
@@ -8104,6 +8147,7 @@
8104
8147
  "type": {
8105
8148
  "text": "number"
8106
8149
  },
8150
+ "description": "Sets the maximum number of text rows before the content starts scrolling.",
8107
8151
  "attribute": "maximum-rows",
8108
8152
  "reflects": true
8109
8153
  },
@@ -8113,6 +8157,7 @@
8113
8157
  "type": {
8114
8158
  "text": "number"
8115
8159
  },
8160
+ "description": "Sets the minimum number of text rows the textarea should display",
8116
8161
  "attribute": "minimum-rows",
8117
8162
  "reflects": true
8118
8163
  },
@@ -8122,6 +8167,7 @@
8122
8167
  "type": {
8123
8168
  "text": "string"
8124
8169
  },
8170
+ "description": "The [name](https://developer.mozilla.org/en-US/docs/Web/HTML/Reference/Elements/input#name) of the input field when submitting the form",
8125
8171
  "attribute": "name",
8126
8172
  "reflects": true
8127
8173
  },
@@ -8131,6 +8177,8 @@
8131
8177
  "type": {
8132
8178
  "text": "string"
8133
8179
  },
8180
+ "description": "Set a text that is shown in the textarea when it doesn't have a value.\n\nPlaceholder text should not be used as a substitute for labeling the element with a visible label.",
8181
+ "summary": "Shown in the textarea when it doesn't have a value",
8134
8182
  "attribute": "placeholder",
8135
8183
  "reflects": true
8136
8184
  },
@@ -8141,7 +8189,7 @@
8141
8189
  "text": "boolean"
8142
8190
  },
8143
8191
  "default": "false",
8144
- "deprecated": "Use the native readonly attribute instead. Here for API consistency with `w-textfield`.",
8192
+ "deprecated": "Use the native `readonly` attribute instead",
8145
8193
  "attribute": "read-only",
8146
8194
  "reflects": true
8147
8195
  },
@@ -8152,6 +8200,7 @@
8152
8200
  "text": "boolean"
8153
8201
  },
8154
8202
  "default": "false",
8203
+ "description": "Whether the input can be selected but not changed by the user",
8155
8204
  "attribute": "readonly",
8156
8205
  "reflects": true
8157
8206
  },
@@ -8162,6 +8211,7 @@
8162
8211
  "text": "boolean"
8163
8212
  },
8164
8213
  "default": "false",
8214
+ "description": "Whether user input is required on the input before form submission",
8165
8215
  "attribute": "required",
8166
8216
  "reflects": true
8167
8217
  },
@@ -8171,6 +8221,7 @@
8171
8221
  "type": {
8172
8222
  "text": "string"
8173
8223
  },
8224
+ "description": "Lets you set the current value",
8174
8225
  "attribute": "value",
8175
8226
  "reflects": true
8176
8227
  },
@@ -8181,17 +8232,10 @@
8181
8232
  "text": "boolean"
8182
8233
  },
8183
8234
  "default": "false",
8235
+ "description": "Show an icon behind the label indicating the field is optional",
8184
8236
  "attribute": "optional",
8185
8237
  "reflects": true
8186
8238
  },
8187
- {
8188
- "kind": "field",
8189
- "name": "minHeight"
8190
- },
8191
- {
8192
- "kind": "field",
8193
- "name": "maxHeight"
8194
- },
8195
8239
  {
8196
8240
  "kind": "field",
8197
8241
  "name": "_textarea",
@@ -8355,6 +8399,8 @@
8355
8399
  "text": "boolean"
8356
8400
  },
8357
8401
  "default": "false",
8402
+ "description": "Keep in mind that using disabled in its current form is an anti-pattern.\n\nThere will always be users who don't understand why an element is disabled, or users who can't even see that it is disabled because of poor lighting conditions or other reasons.\n\nPlease consider more informative alternatives before choosing to use disabled on an element.",
8403
+ "summary": "Makes the element not focusable and hides it from form submits",
8358
8404
  "fieldName": "disabled"
8359
8405
  },
8360
8406
  {
@@ -8363,6 +8409,7 @@
8363
8409
  "text": "boolean"
8364
8410
  },
8365
8411
  "default": "false",
8412
+ "description": "Mark the form field as invalid.\n\nMake sure to also set a `help-text` to help users fix the validation problem.",
8366
8413
  "fieldName": "invalid"
8367
8414
  },
8368
8415
  {
@@ -8370,6 +8417,7 @@
8370
8417
  "type": {
8371
8418
  "text": "string"
8372
8419
  },
8420
+ "description": "Either a `label` or an `aria-label` must be provided.",
8373
8421
  "fieldName": "label"
8374
8422
  },
8375
8423
  {
@@ -8377,6 +8425,8 @@
8377
8425
  "type": {
8378
8426
  "text": "string"
8379
8427
  },
8428
+ "description": "Use in combination with `invalid` to show as a validation error message,\nor on its own to show a help text.",
8429
+ "summary": "Description shown below the input field",
8380
8430
  "fieldName": "helpText"
8381
8431
  },
8382
8432
  {
@@ -8384,6 +8434,7 @@
8384
8434
  "type": {
8385
8435
  "text": "number"
8386
8436
  },
8437
+ "description": "Sets the maximum number of text rows before the content starts scrolling.",
8387
8438
  "fieldName": "maxRows"
8388
8439
  },
8389
8440
  {
@@ -8391,6 +8442,7 @@
8391
8442
  "type": {
8392
8443
  "text": "number"
8393
8444
  },
8445
+ "description": "Sets the minimum number of text rows the textarea should display",
8394
8446
  "fieldName": "minRows"
8395
8447
  },
8396
8448
  {
@@ -8398,6 +8450,7 @@
8398
8450
  "type": {
8399
8451
  "text": "string"
8400
8452
  },
8453
+ "description": "The [name](https://developer.mozilla.org/en-US/docs/Web/HTML/Reference/Elements/input#name) of the input field when submitting the form",
8401
8454
  "fieldName": "name"
8402
8455
  },
8403
8456
  {
@@ -8405,6 +8458,8 @@
8405
8458
  "type": {
8406
8459
  "text": "string"
8407
8460
  },
8461
+ "description": "Set a text that is shown in the textarea when it doesn't have a value.\n\nPlaceholder text should not be used as a substitute for labeling the element with a visible label.",
8462
+ "summary": "Shown in the textarea when it doesn't have a value",
8408
8463
  "fieldName": "placeholder"
8409
8464
  },
8410
8465
  {
@@ -8413,7 +8468,7 @@
8413
8468
  "text": "boolean"
8414
8469
  },
8415
8470
  "default": "false",
8416
- "deprecated": "Use the native readonly attribute instead. Here for API consistency with `w-textfield`.",
8471
+ "deprecated": "Use the native `readonly` attribute instead",
8417
8472
  "fieldName": "readOnly"
8418
8473
  },
8419
8474
  {
@@ -8422,6 +8477,7 @@
8422
8477
  "text": "boolean"
8423
8478
  },
8424
8479
  "default": "false",
8480
+ "description": "Whether the input can be selected but not changed by the user",
8425
8481
  "fieldName": "readonly"
8426
8482
  },
8427
8483
  {
@@ -8430,6 +8486,7 @@
8430
8486
  "text": "boolean"
8431
8487
  },
8432
8488
  "default": "false",
8489
+ "description": "Whether user input is required on the input before form submission",
8433
8490
  "fieldName": "required"
8434
8491
  },
8435
8492
  {
@@ -8437,6 +8494,7 @@
8437
8494
  "type": {
8438
8495
  "text": "string"
8439
8496
  },
8497
+ "description": "Lets you set the current value",
8440
8498
  "fieldName": "value"
8441
8499
  },
8442
8500
  {
@@ -8445,6 +8503,7 @@
8445
8503
  "text": "boolean"
8446
8504
  },
8447
8505
  "default": "false",
8506
+ "description": "Show an icon behind the label indicating the field is optional",
8448
8507
  "fieldName": "optional"
8449
8508
  }
8450
8509
  ],
@@ -68,58 +68,46 @@ When `search` or `clear` is enabled, `w-affix` renders a button and a matching `
68
68
 
69
69
  ### Prefix Label
70
70
 
71
- <style-isolate>
72
- <w-textfield label="Price">
73
- <w-affix slot="prefix" label="kr"></w-affix>
74
- </w-textfield>
75
- </style-isolate>
76
-
71
+ <elements-example>
72
+
77
73
  ```html
78
74
  <w-textfield label="Price">
79
75
  <w-affix slot="suffix" label="kr"></w-affix>
80
76
  </w-textfield>
81
77
  ```
82
78
 
83
- ### Suffix Label
79
+ </elements-example>
84
80
 
85
- <style-isolate>
86
- <w-textfield label="Price">
87
- <w-affix slot="suffix" label="kr"></w-affix>
88
- </w-textfield>
89
- </style-isolate>
81
+ ### Suffix Label
90
82
 
83
+ <elements-example>
84
+
91
85
  ```html
92
86
  <w-textfield label="Price">
93
87
  <w-affix slot="suffix" label="kr"></w-affix>
94
88
  </w-textfield>
95
89
  ```
96
90
 
97
- ### Prefix Search Icon
91
+ </elements-example>
98
92
 
99
- <style-isolate>
100
- <w-textfield label="Search">
101
- <w-affix slot="prefix" search></w-affix>
102
- </w-textfield>
103
- </style-isolate>
93
+ ### Prefix Search Icon
104
94
 
95
+ <elements-example>
96
+
105
97
  ```html
106
98
  <w-textfield label="Search">
107
99
  <w-affix slot="prefix" search></w-affix>
108
100
  </w-textfield>
109
101
  ```
110
102
 
103
+ </elements-example>
104
+
111
105
  ### Suffix Search Icon
112
106
 
113
107
  If you wrap the textfield with affix in a form element, clicking the search button will automatically submit the form
114
108
 
115
- <style-isolate>
116
- <form>
117
- <w-textfield label="Search">
118
- <w-affix slot="suffix" search></w-affix>
119
- </w-textfield>
120
- </form>
121
- </style-isolate>
122
-
109
+ <elements-example>
110
+
123
111
  ```html
124
112
  <form>
125
113
  <w-textfield label="Search">
@@ -128,36 +116,34 @@ If you wrap the textfield with affix in a form element, clicking the search butt
128
116
  </form>
129
117
  ```
130
118
 
119
+ </elements-example>
120
+
131
121
  ### Suffix Clear Icon
132
122
 
133
123
  Clicking the clear button will reset the textfield
134
124
 
135
- <style-isolate>
136
- <w-textfield label="Search input">
137
- <w-affix slot="suffix" clear></w-affix>
138
- </w-textfield>
139
- </style-isolate>
140
-
125
+ <elements-example>
126
+
141
127
  ```html
142
128
  <w-textfield label="Search input">
143
129
  <w-affix slot="suffix" clear></w-affix>
144
130
  </w-textfield>
145
131
  ```
146
132
 
147
- ### Icons
133
+ </elements-example>
148
134
 
149
- <style-isolate>
150
- <w-textfield label="Award">
151
- <w-affix slot="prefix" icon="AwardMedal"></w-affix>
152
- </w-textfield>
153
- </style-isolate>
135
+ ### Icons
154
136
 
137
+ <elements-example>
138
+
155
139
  ```html
156
140
  <w-textfield label="Award">
157
141
  <w-affix slot="prefix" icon="AwardMedal"></w-affix>
158
142
  </w-textfield>
159
143
  ```
160
144
 
145
+ </elements-example>
146
+
161
147
  ## API Documentation
162
148
 
163
149
  ### Properties