@nordhealth/components 1.0.0-beta.4 → 1.0.0-beta.5
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.
- package/custom-elements.json +109 -109
- package/lib/EmptyState.js.map +1 -1
- package/lib/bundle.js.map +1 -1
- package/lib/src/empty-state/EmptyState.d.ts +2 -2
- package/package.json +2 -2
package/custom-elements.json
CHANGED
|
@@ -798,6 +798,114 @@
|
|
|
798
798
|
],
|
|
799
799
|
"readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use clear and accurate labels.\n- Use established button colors appropriately. For example, only use a danger button style for an action that’s difficult or impossible to undo.\n- Prioritize the most important actions. Too many buttons will cause confusion.\n- Be consistent with positioning of buttons in the user interface.\n- Use strong, actionable verbs in labels such as “Add”, “Close”, “Cancel”, or “Save”.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use buttons to link to other pages. Use regular link or a plain style instead where necessary.\n- Don’t use buttons for navigation where the link appears within or following a sentence.\n- Don’t use labels such as “Read more”, “Click here” or “More”.\n\n</div>\n\n---\n\n## Content guidelines\n\nButton labels should be clear, accurate and predictable. It should be possible for the user to understand what will happen when they click a button:\n\n<div class=\"n-usage n-usage-do\">View user settings</div>\n<div class=\"n-usage n-usage-dont\">Click here</div>\n\nWhen writing button labels, always write them in sentence case, not title case. The first word should be capitalized and the rest lowercase (unless a proper noun):\n\n<div class=\"n-usage n-usage-do\">My tasks</div>\n<div class=\"n-usage n-usage-dont\">My Tasks</div>\n\nAvoid unnecessary words and articles in button labels, such as “the”, “an” or “a”:\n\n<div class=\"n-usage n-usage-do\">Add item</div>\n<div class=\"n-usage n-usage-dont\">Add an item</div>\n\n---\n\n## Variants\n\nThis section describes the different component variants, their purpose, and when to use each variant.\n\n| Name | Purpose |\n| ---------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |\n| `default` | Default style is the most common button variant. Only switch to another variant if you need to adjust the visual weight of the element. |\n| `primary` | Primary style is reserved for main call-to-actions. Should be used only once per content area or panel, e.g. for a “Save” action. |\n| `dashed` | Dashed style should be used for actions that trigger filtering. |\n| `danger` | Danger style should be used for actions that delete data or otherwise make it hard to undo the action. |\n| `plain` | Used for less important or less common actions. Can be also used for linking to other pages. |\n| `disabled` | Used for actions that aren’t currently available or not available anymore. Also prevents users from being able to interact with the component, and conveys its inactive state to assistive technologies. |\n\n---\n\n## Additional considerations\n\n- Users of assistive technology expect a button to submit data or do an action. If you need the button to navigate into another view, use the `href` property which will output `<a>` tag instead of a `<button>`.\n- When you need to disable a button, use `disabled` property as it conveys this information correctly to assistive technologies like screen readers.\n- Button component provides 3 size variants; small, medium and large. The large size should only be used for marketing purposes or on areas such as an empty space/content notice.\n"
|
|
800
800
|
},
|
|
801
|
+
{
|
|
802
|
+
"kind": "javascript-module",
|
|
803
|
+
"path": "src/card/Card.ts",
|
|
804
|
+
"declarations": [
|
|
805
|
+
{
|
|
806
|
+
"kind": "class",
|
|
807
|
+
"description": "Cards are shadowed surfaces that display content and actions on a\nsingle topic. They should be easy to scan for relevant and\nactionable information.",
|
|
808
|
+
"name": "Card",
|
|
809
|
+
"slots": [
|
|
810
|
+
{
|
|
811
|
+
"description": "The card content.",
|
|
812
|
+
"name": ""
|
|
813
|
+
},
|
|
814
|
+
{
|
|
815
|
+
"description": "Optional slot that holds a header for the card.",
|
|
816
|
+
"name": "header"
|
|
817
|
+
},
|
|
818
|
+
{
|
|
819
|
+
"description": "Optional slot that holds footer content for the card.",
|
|
820
|
+
"name": "footer"
|
|
821
|
+
}
|
|
822
|
+
],
|
|
823
|
+
"members": [
|
|
824
|
+
{
|
|
825
|
+
"kind": "field",
|
|
826
|
+
"name": "headerSlot",
|
|
827
|
+
"privacy": "private",
|
|
828
|
+
"default": "new SlotController(this, \"header\")"
|
|
829
|
+
},
|
|
830
|
+
{
|
|
831
|
+
"kind": "field",
|
|
832
|
+
"name": "footerSlot",
|
|
833
|
+
"privacy": "private",
|
|
834
|
+
"default": "new SlotController(this, \"footer\")"
|
|
835
|
+
},
|
|
836
|
+
{
|
|
837
|
+
"kind": "field",
|
|
838
|
+
"name": "padding",
|
|
839
|
+
"type": {
|
|
840
|
+
"text": "\"m\" | \"l\" | \"none\""
|
|
841
|
+
},
|
|
842
|
+
"default": "\"m\"",
|
|
843
|
+
"description": "Controls the padding of card component. When set to “none”,\nthe header and footer slots will still have padding.",
|
|
844
|
+
"attribute": "padding",
|
|
845
|
+
"reflects": true
|
|
846
|
+
},
|
|
847
|
+
{
|
|
848
|
+
"kind": "field",
|
|
849
|
+
"name": "_warningLogged",
|
|
850
|
+
"type": {
|
|
851
|
+
"text": "boolean"
|
|
852
|
+
},
|
|
853
|
+
"privacy": "private",
|
|
854
|
+
"static": true,
|
|
855
|
+
"default": "false",
|
|
856
|
+
"inheritedFrom": {
|
|
857
|
+
"name": "DraftComponentMixin",
|
|
858
|
+
"module": "src/common/mixins/DraftComponentMixin.ts"
|
|
859
|
+
}
|
|
860
|
+
}
|
|
861
|
+
],
|
|
862
|
+
"attributes": [
|
|
863
|
+
{
|
|
864
|
+
"name": "padding",
|
|
865
|
+
"type": {
|
|
866
|
+
"text": "\"m\" | \"l\" | \"none\""
|
|
867
|
+
},
|
|
868
|
+
"default": "\"m\"",
|
|
869
|
+
"description": "Controls the padding of card component. When set to “none”,\nthe header and footer slots will still have padding.",
|
|
870
|
+
"fieldName": "padding"
|
|
871
|
+
}
|
|
872
|
+
],
|
|
873
|
+
"mixins": [
|
|
874
|
+
{
|
|
875
|
+
"name": "DraftComponentMixin",
|
|
876
|
+
"module": "/src/common/mixins/DraftComponentMixin.js"
|
|
877
|
+
}
|
|
878
|
+
],
|
|
879
|
+
"superclass": {
|
|
880
|
+
"name": "LitElement",
|
|
881
|
+
"package": "lit"
|
|
882
|
+
},
|
|
883
|
+
"status": "draft",
|
|
884
|
+
"category": "structure",
|
|
885
|
+
"tagName": "nord-card",
|
|
886
|
+
"customElement": true
|
|
887
|
+
}
|
|
888
|
+
],
|
|
889
|
+
"exports": [
|
|
890
|
+
{
|
|
891
|
+
"kind": "js",
|
|
892
|
+
"name": "default",
|
|
893
|
+
"declaration": {
|
|
894
|
+
"name": "Card",
|
|
895
|
+
"module": "src/card/Card.ts"
|
|
896
|
+
}
|
|
897
|
+
},
|
|
898
|
+
{
|
|
899
|
+
"kind": "custom-element-definition",
|
|
900
|
+
"name": "nord-card",
|
|
901
|
+
"declaration": {
|
|
902
|
+
"name": "Card",
|
|
903
|
+
"module": "src/card/Card.ts"
|
|
904
|
+
}
|
|
905
|
+
}
|
|
906
|
+
],
|
|
907
|
+
"readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use to display content and actions on a single topic inside a container.\n- Use to visually separate specific parts of content in an application view.\n- Use to wrap a form into a container, for example a login form.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use when you need to capture user’s attention in a prominent way.\n- Don’t use to inform user about important changes or conditions in the interface.\n- Don’t use multiple primary buttons inside a card. A card should only contain a single primary action.\n\n</div>\n"
|
|
908
|
+
},
|
|
801
909
|
{
|
|
802
910
|
"kind": "javascript-module",
|
|
803
911
|
"path": "src/calendar/Calendar.ts",
|
|
@@ -1909,114 +2017,6 @@
|
|
|
1909
2017
|
],
|
|
1910
2018
|
"readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use for making it possible to choose one or more options from a limited number of options.\n- Use for “accepting terms of service” and similar functionality.\n- Use in forms to toggle something on or off.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use when you have more than 10 options to choose from.\n- Don’t change the selection of another checkbox when another one is clicked. Only exception is when a checkbox is used to make a bulk selection of multiple items.\n\n</div>\n\n---\n\n## Content guidelines\n\nCheckbox labels should be clear, accurate and predictable. It should be possible for the user to understand what they are selecting:\n\n<div class=\"n-usage n-usage-do\">User settings</div>\n<div class=\"n-usage n-usage-dont\">Option 1</div>\n\nWhen writing checkbox labels, always write them in sentence case, not title case. The first word should be capitalized and the rest lowercase (unless a proper noun):\n\n<div class=\"n-usage n-usage-do\">User settings</div>\n<div class=\"n-usage n-usage-dont\">User Settings</div>\n\nAvoid ending in punctuation if it’s a single sentence, word, or a fragment:\n\n<div class=\"n-usage n-usage-do\">Show dashboard</div>\n<div class=\"n-usage n-usage-dont\">Show dashboard.</div>\n\nDo not use commas or semicolons at the end of each line\n\n<div class=\"n-usage n-usage-do\">Patients</div>\n<div class=\"n-usage n-usage-dont\">Patients;</div>\n"
|
|
1911
2019
|
},
|
|
1912
|
-
{
|
|
1913
|
-
"kind": "javascript-module",
|
|
1914
|
-
"path": "src/card/Card.ts",
|
|
1915
|
-
"declarations": [
|
|
1916
|
-
{
|
|
1917
|
-
"kind": "class",
|
|
1918
|
-
"description": "Cards are shadowed surfaces that display content and actions on a\nsingle topic. They should be easy to scan for relevant and\nactionable information.",
|
|
1919
|
-
"name": "Card",
|
|
1920
|
-
"slots": [
|
|
1921
|
-
{
|
|
1922
|
-
"description": "The card content.",
|
|
1923
|
-
"name": ""
|
|
1924
|
-
},
|
|
1925
|
-
{
|
|
1926
|
-
"description": "Optional slot that holds a header for the card.",
|
|
1927
|
-
"name": "header"
|
|
1928
|
-
},
|
|
1929
|
-
{
|
|
1930
|
-
"description": "Optional slot that holds footer content for the card.",
|
|
1931
|
-
"name": "footer"
|
|
1932
|
-
}
|
|
1933
|
-
],
|
|
1934
|
-
"members": [
|
|
1935
|
-
{
|
|
1936
|
-
"kind": "field",
|
|
1937
|
-
"name": "headerSlot",
|
|
1938
|
-
"privacy": "private",
|
|
1939
|
-
"default": "new SlotController(this, \"header\")"
|
|
1940
|
-
},
|
|
1941
|
-
{
|
|
1942
|
-
"kind": "field",
|
|
1943
|
-
"name": "footerSlot",
|
|
1944
|
-
"privacy": "private",
|
|
1945
|
-
"default": "new SlotController(this, \"footer\")"
|
|
1946
|
-
},
|
|
1947
|
-
{
|
|
1948
|
-
"kind": "field",
|
|
1949
|
-
"name": "padding",
|
|
1950
|
-
"type": {
|
|
1951
|
-
"text": "\"m\" | \"l\" | \"none\""
|
|
1952
|
-
},
|
|
1953
|
-
"default": "\"m\"",
|
|
1954
|
-
"description": "Controls the padding of card component. When set to “none”,\nthe header and footer slots will still have padding.",
|
|
1955
|
-
"attribute": "padding",
|
|
1956
|
-
"reflects": true
|
|
1957
|
-
},
|
|
1958
|
-
{
|
|
1959
|
-
"kind": "field",
|
|
1960
|
-
"name": "_warningLogged",
|
|
1961
|
-
"type": {
|
|
1962
|
-
"text": "boolean"
|
|
1963
|
-
},
|
|
1964
|
-
"privacy": "private",
|
|
1965
|
-
"static": true,
|
|
1966
|
-
"default": "false",
|
|
1967
|
-
"inheritedFrom": {
|
|
1968
|
-
"name": "DraftComponentMixin",
|
|
1969
|
-
"module": "src/common/mixins/DraftComponentMixin.ts"
|
|
1970
|
-
}
|
|
1971
|
-
}
|
|
1972
|
-
],
|
|
1973
|
-
"attributes": [
|
|
1974
|
-
{
|
|
1975
|
-
"name": "padding",
|
|
1976
|
-
"type": {
|
|
1977
|
-
"text": "\"m\" | \"l\" | \"none\""
|
|
1978
|
-
},
|
|
1979
|
-
"default": "\"m\"",
|
|
1980
|
-
"description": "Controls the padding of card component. When set to “none”,\nthe header and footer slots will still have padding.",
|
|
1981
|
-
"fieldName": "padding"
|
|
1982
|
-
}
|
|
1983
|
-
],
|
|
1984
|
-
"mixins": [
|
|
1985
|
-
{
|
|
1986
|
-
"name": "DraftComponentMixin",
|
|
1987
|
-
"module": "/src/common/mixins/DraftComponentMixin.js"
|
|
1988
|
-
}
|
|
1989
|
-
],
|
|
1990
|
-
"superclass": {
|
|
1991
|
-
"name": "LitElement",
|
|
1992
|
-
"package": "lit"
|
|
1993
|
-
},
|
|
1994
|
-
"status": "draft",
|
|
1995
|
-
"category": "structure",
|
|
1996
|
-
"tagName": "nord-card",
|
|
1997
|
-
"customElement": true
|
|
1998
|
-
}
|
|
1999
|
-
],
|
|
2000
|
-
"exports": [
|
|
2001
|
-
{
|
|
2002
|
-
"kind": "js",
|
|
2003
|
-
"name": "default",
|
|
2004
|
-
"declaration": {
|
|
2005
|
-
"name": "Card",
|
|
2006
|
-
"module": "src/card/Card.ts"
|
|
2007
|
-
}
|
|
2008
|
-
},
|
|
2009
|
-
{
|
|
2010
|
-
"kind": "custom-element-definition",
|
|
2011
|
-
"name": "nord-card",
|
|
2012
|
-
"declaration": {
|
|
2013
|
-
"name": "Card",
|
|
2014
|
-
"module": "src/card/Card.ts"
|
|
2015
|
-
}
|
|
2016
|
-
}
|
|
2017
|
-
],
|
|
2018
|
-
"readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use to display content and actions on a single topic inside a container.\n- Use to visually separate specific parts of content in an application view.\n- Use to wrap a form into a container, for example a login form.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use when you need to capture user’s attention in a prominent way.\n- Don’t use to inform user about important changes or conditions in the interface.\n- Don’t use multiple primary buttons inside a card. A card should only contain a single primary action.\n\n</div>\n"
|
|
2019
|
-
},
|
|
2020
2020
|
{
|
|
2021
2021
|
"kind": "javascript-module",
|
|
2022
2022
|
"path": "src/command-menu/CommandMenu.ts",
|
|
@@ -4611,7 +4611,7 @@
|
|
|
4611
4611
|
"declarations": [
|
|
4612
4612
|
{
|
|
4613
4613
|
"kind": "class",
|
|
4614
|
-
"description": "Empty state can be used when there is no data to display to\ndescribe what the user can do next. Empty state
|
|
4614
|
+
"description": "Empty state can be used when there is no data to display to\ndescribe what the user can do next. Empty state provides\nexplanation and guidance to help user progress.",
|
|
4615
4615
|
"name": "EmptyState",
|
|
4616
4616
|
"slots": [
|
|
4617
4617
|
{
|
package/lib/EmptyState.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"EmptyState.js","sources":["../src/empty-state/EmptyState.ts"],"sourcesContent":["import { LitElement, html } from \"lit\"\nimport { customElement } from \"lit/decorators.js\"\nimport { DraftComponentMixin } from \"../common/mixins/DraftComponentMixin.js\"\n\nimport componentStyle from \"../common/styles/Component.css\"\nimport style from \"./EmptyState.css\"\n\n/**\n * Empty state can be used when there is no data to display to\n * describe what the user can do next. Empty state
|
|
1
|
+
{"version":3,"file":"EmptyState.js","sources":["../src/empty-state/EmptyState.ts"],"sourcesContent":["import { LitElement, html } from \"lit\"\nimport { customElement } from \"lit/decorators.js\"\nimport { DraftComponentMixin } from \"../common/mixins/DraftComponentMixin.js\"\n\nimport componentStyle from \"../common/styles/Component.css\"\nimport style from \"./EmptyState.css\"\n\n/**\n * Empty state can be used when there is no data to display to\n * describe what the user can do next. Empty state provides\n * explanation and guidance to help user progress.\n *\n * @status draft\n * @category feedback\n * @slot - default slot\n */\n@customElement(\"nord-empty-state\")\nexport default class EmptyState extends DraftComponentMixin(LitElement) {\n static styles = [componentStyle, style]\n\n render() {\n return html`<div class=\"n-empty-state\">\n <slot></slot>\n </div>`\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n \"nord-empty-state\": EmptyState\n }\n}\n"],"names":["EmptyState","DraftComponentMixin","LitElement","render","html","componentStyle","style","customElement"],"mappings":"giCAiBA,IAAqBA,EAArB,cAAwCC,EAAoBC,IAG1DC,SACE,OAAOC,CAAI,mDAHNJ,SAAS,CAACK,EAAgBC,GADdN,KADpBO,EAAc,qBACMP,SAAAA"}
|