@genesislcap/foundation-ui 14.401.3 → 14.402.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.
- package/dist/custom-elements.json +431 -363
- package/dist/dts/status-pill/status-pill.d.ts +33 -0
- package/dist/dts/status-pill/status-pill.d.ts.map +1 -1
- package/dist/dts/status-pill/status-pill.template.d.ts.map +1 -1
- package/dist/esm/status-pill/status-pill.js +70 -3
- package/dist/esm/status-pill/status-pill.template.js +28 -26
- package/package.json +19 -19
|
@@ -1877,369 +1877,6 @@
|
|
|
1877
1877
|
}
|
|
1878
1878
|
]
|
|
1879
1879
|
},
|
|
1880
|
-
{
|
|
1881
|
-
"kind": "javascript-module",
|
|
1882
|
-
"path": "src/_common/base-file-component.ts",
|
|
1883
|
-
"declarations": [
|
|
1884
|
-
{
|
|
1885
|
-
"kind": "class",
|
|
1886
|
-
"description": "Abstract base class for file handling components\nProvides common functionality for file selection, validation, and UI state management",
|
|
1887
|
-
"name": "BaseFileComponent",
|
|
1888
|
-
"members": [
|
|
1889
|
-
{
|
|
1890
|
-
"kind": "field",
|
|
1891
|
-
"name": "fileInput",
|
|
1892
|
-
"type": {
|
|
1893
|
-
"text": "HTMLInputElement"
|
|
1894
|
-
},
|
|
1895
|
-
"privacy": "public"
|
|
1896
|
-
},
|
|
1897
|
-
{
|
|
1898
|
-
"kind": "field",
|
|
1899
|
-
"name": "selectedFile",
|
|
1900
|
-
"type": {
|
|
1901
|
-
"text": "File | null"
|
|
1902
|
-
},
|
|
1903
|
-
"privacy": "protected",
|
|
1904
|
-
"default": "null"
|
|
1905
|
-
},
|
|
1906
|
-
{
|
|
1907
|
-
"kind": "field",
|
|
1908
|
-
"name": "label",
|
|
1909
|
-
"type": {
|
|
1910
|
-
"text": "string"
|
|
1911
|
-
}
|
|
1912
|
-
},
|
|
1913
|
-
{
|
|
1914
|
-
"kind": "field",
|
|
1915
|
-
"name": "accept",
|
|
1916
|
-
"type": {
|
|
1917
|
-
"text": "string"
|
|
1918
|
-
},
|
|
1919
|
-
"default": "''"
|
|
1920
|
-
},
|
|
1921
|
-
{
|
|
1922
|
-
"kind": "field",
|
|
1923
|
-
"name": "fileSizeLimitBytes",
|
|
1924
|
-
"default": "10_485_760",
|
|
1925
|
-
"type": {
|
|
1926
|
-
"text": "number"
|
|
1927
|
-
}
|
|
1928
|
-
},
|
|
1929
|
-
{
|
|
1930
|
-
"kind": "field",
|
|
1931
|
-
"name": "fileName",
|
|
1932
|
-
"type": {
|
|
1933
|
-
"text": "string"
|
|
1934
|
-
},
|
|
1935
|
-
"default": "''"
|
|
1936
|
-
},
|
|
1937
|
-
{
|
|
1938
|
-
"kind": "field",
|
|
1939
|
-
"name": "isProcessing",
|
|
1940
|
-
"type": {
|
|
1941
|
-
"text": "boolean"
|
|
1942
|
-
},
|
|
1943
|
-
"default": "false"
|
|
1944
|
-
},
|
|
1945
|
-
{
|
|
1946
|
-
"kind": "method",
|
|
1947
|
-
"name": "handleClick",
|
|
1948
|
-
"privacy": "public",
|
|
1949
|
-
"description": "Opens the file picker dialog\nClears any previous file selection before opening"
|
|
1950
|
-
},
|
|
1951
|
-
{
|
|
1952
|
-
"kind": "method",
|
|
1953
|
-
"name": "onInputChange",
|
|
1954
|
-
"privacy": "public",
|
|
1955
|
-
"parameters": [
|
|
1956
|
-
{
|
|
1957
|
-
"name": "e",
|
|
1958
|
-
"type": {
|
|
1959
|
-
"text": "Event"
|
|
1960
|
-
},
|
|
1961
|
-
"description": "The change event from the file input"
|
|
1962
|
-
}
|
|
1963
|
-
],
|
|
1964
|
-
"description": "Handles file selection from the file input\nValidates file size and sets up for processing"
|
|
1965
|
-
},
|
|
1966
|
-
{
|
|
1967
|
-
"kind": "method",
|
|
1968
|
-
"name": "clearSelection",
|
|
1969
|
-
"privacy": "public",
|
|
1970
|
-
"description": "Clears all file selection and processing state\nResets the component to its initial state"
|
|
1971
|
-
},
|
|
1972
|
-
{
|
|
1973
|
-
"kind": "method",
|
|
1974
|
-
"name": "getSelectedFile",
|
|
1975
|
-
"privacy": "public",
|
|
1976
|
-
"description": "Gets the currently selected file object",
|
|
1977
|
-
"return": {
|
|
1978
|
-
"type": {
|
|
1979
|
-
"text": ""
|
|
1980
|
-
}
|
|
1981
|
-
}
|
|
1982
|
-
},
|
|
1983
|
-
{
|
|
1984
|
-
"kind": "method",
|
|
1985
|
-
"name": "showError",
|
|
1986
|
-
"privacy": "protected",
|
|
1987
|
-
"parameters": [
|
|
1988
|
-
{
|
|
1989
|
-
"name": "title",
|
|
1990
|
-
"type": {
|
|
1991
|
-
"text": "string"
|
|
1992
|
-
},
|
|
1993
|
-
"description": "The error title"
|
|
1994
|
-
},
|
|
1995
|
-
{
|
|
1996
|
-
"name": "message",
|
|
1997
|
-
"type": {
|
|
1998
|
-
"text": "string"
|
|
1999
|
-
},
|
|
2000
|
-
"description": "The error message"
|
|
2001
|
-
}
|
|
2002
|
-
],
|
|
2003
|
-
"description": "Shows an error notification using the unified error handling system"
|
|
2004
|
-
},
|
|
2005
|
-
{
|
|
2006
|
-
"kind": "method",
|
|
2007
|
-
"name": "onFileSelected",
|
|
2008
|
-
"privacy": "protected",
|
|
2009
|
-
"return": {
|
|
2010
|
-
"type": {
|
|
2011
|
-
"text": "void"
|
|
2012
|
-
}
|
|
2013
|
-
},
|
|
2014
|
-
"parameters": [
|
|
2015
|
-
{
|
|
2016
|
-
"name": "files",
|
|
2017
|
-
"type": {
|
|
2018
|
-
"text": "File[]"
|
|
2019
|
-
},
|
|
2020
|
-
"description": "The selected file"
|
|
2021
|
-
}
|
|
2022
|
-
],
|
|
2023
|
-
"description": "Abstract method called when a file is selected"
|
|
2024
|
-
},
|
|
2025
|
-
{
|
|
2026
|
-
"kind": "method",
|
|
2027
|
-
"name": "onFileCleared",
|
|
2028
|
-
"privacy": "protected",
|
|
2029
|
-
"return": {
|
|
2030
|
-
"type": {
|
|
2031
|
-
"text": "void"
|
|
2032
|
-
}
|
|
2033
|
-
},
|
|
2034
|
-
"description": "Abstract method called when file selection is cleared"
|
|
2035
|
-
},
|
|
2036
|
-
{
|
|
2037
|
-
"kind": "field",
|
|
2038
|
-
"name": "_presentation",
|
|
2039
|
-
"type": {
|
|
2040
|
-
"text": "ComponentPresentation | null | undefined"
|
|
2041
|
-
},
|
|
2042
|
-
"privacy": "private",
|
|
2043
|
-
"default": "void 0",
|
|
2044
|
-
"inheritedFrom": {
|
|
2045
|
-
"name": "FoundationElement",
|
|
2046
|
-
"module": "src/foundation-element/foundation-element.ts"
|
|
2047
|
-
}
|
|
2048
|
-
},
|
|
2049
|
-
{
|
|
2050
|
-
"kind": "field",
|
|
2051
|
-
"name": "$presentation",
|
|
2052
|
-
"type": {
|
|
2053
|
-
"text": "ComponentPresentation | null"
|
|
2054
|
-
},
|
|
2055
|
-
"privacy": "public",
|
|
2056
|
-
"description": "A property which resolves the ComponentPresentation instance\nfor the current component.",
|
|
2057
|
-
"inheritedFrom": {
|
|
2058
|
-
"name": "FoundationElement",
|
|
2059
|
-
"module": "src/foundation-element/foundation-element.ts"
|
|
2060
|
-
}
|
|
2061
|
-
},
|
|
2062
|
-
{
|
|
2063
|
-
"kind": "field",
|
|
2064
|
-
"name": "template",
|
|
2065
|
-
"type": {
|
|
2066
|
-
"text": "ElementViewTemplate | void | null"
|
|
2067
|
-
},
|
|
2068
|
-
"privacy": "public",
|
|
2069
|
-
"description": "Sets the template of the element instance. When undefined,\nthe element will attempt to resolve the template from\nthe associated presentation or custom element definition.",
|
|
2070
|
-
"inheritedFrom": {
|
|
2071
|
-
"name": "FoundationElement",
|
|
2072
|
-
"module": "src/foundation-element/foundation-element.ts"
|
|
2073
|
-
}
|
|
2074
|
-
},
|
|
2075
|
-
{
|
|
2076
|
-
"kind": "method",
|
|
2077
|
-
"name": "templateChanged",
|
|
2078
|
-
"privacy": "protected",
|
|
2079
|
-
"return": {
|
|
2080
|
-
"type": {
|
|
2081
|
-
"text": "void"
|
|
2082
|
-
}
|
|
2083
|
-
},
|
|
2084
|
-
"inheritedFrom": {
|
|
2085
|
-
"name": "FoundationElement",
|
|
2086
|
-
"module": "src/foundation-element/foundation-element.ts"
|
|
2087
|
-
}
|
|
2088
|
-
},
|
|
2089
|
-
{
|
|
2090
|
-
"kind": "field",
|
|
2091
|
-
"name": "styles",
|
|
2092
|
-
"type": {
|
|
2093
|
-
"text": "ElementStyles | void | null"
|
|
2094
|
-
},
|
|
2095
|
-
"privacy": "public",
|
|
2096
|
-
"description": "Sets the default styles for the element instance. When undefined,\nthe element will attempt to resolve default styles from\nthe associated presentation or custom element definition.",
|
|
2097
|
-
"inheritedFrom": {
|
|
2098
|
-
"name": "FoundationElement",
|
|
2099
|
-
"module": "src/foundation-element/foundation-element.ts"
|
|
2100
|
-
}
|
|
2101
|
-
},
|
|
2102
|
-
{
|
|
2103
|
-
"kind": "method",
|
|
2104
|
-
"name": "stylesChanged",
|
|
2105
|
-
"privacy": "protected",
|
|
2106
|
-
"return": {
|
|
2107
|
-
"type": {
|
|
2108
|
-
"text": "void"
|
|
2109
|
-
}
|
|
2110
|
-
},
|
|
2111
|
-
"inheritedFrom": {
|
|
2112
|
-
"name": "FoundationElement",
|
|
2113
|
-
"module": "src/foundation-element/foundation-element.ts"
|
|
2114
|
-
}
|
|
2115
|
-
},
|
|
2116
|
-
{
|
|
2117
|
-
"kind": "method",
|
|
2118
|
-
"name": "compose",
|
|
2119
|
-
"privacy": "public",
|
|
2120
|
-
"static": true,
|
|
2121
|
-
"return": {
|
|
2122
|
-
"type": {
|
|
2123
|
-
"text": "(\n overrideDefinition?: OverrideFoundationElementDefinition<T>\n ) => FoundationElementRegistry<T, K>"
|
|
2124
|
-
}
|
|
2125
|
-
},
|
|
2126
|
-
"parameters": [
|
|
2127
|
-
{
|
|
2128
|
-
"name": "this",
|
|
2129
|
-
"type": {
|
|
2130
|
-
"text": "K"
|
|
2131
|
-
}
|
|
2132
|
-
},
|
|
2133
|
-
{
|
|
2134
|
-
"name": "elementDefinition",
|
|
2135
|
-
"type": {
|
|
2136
|
-
"text": "T"
|
|
2137
|
-
},
|
|
2138
|
-
"description": "The definition of the element to create the registry\nfunction for."
|
|
2139
|
-
}
|
|
2140
|
-
],
|
|
2141
|
-
"description": "Defines an element registry function with a set of element definition defaults.",
|
|
2142
|
-
"inheritedFrom": {
|
|
2143
|
-
"name": "FoundationElement",
|
|
2144
|
-
"module": "src/foundation-element/foundation-element.ts"
|
|
2145
|
-
}
|
|
2146
|
-
}
|
|
2147
|
-
],
|
|
2148
|
-
"attributes": [
|
|
2149
|
-
{
|
|
2150
|
-
"name": "label",
|
|
2151
|
-
"type": {
|
|
2152
|
-
"text": "string"
|
|
2153
|
-
},
|
|
2154
|
-
"fieldName": "label"
|
|
2155
|
-
},
|
|
2156
|
-
{
|
|
2157
|
-
"name": "accept",
|
|
2158
|
-
"type": {
|
|
2159
|
-
"text": "string"
|
|
2160
|
-
},
|
|
2161
|
-
"default": "''",
|
|
2162
|
-
"fieldName": "accept"
|
|
2163
|
-
},
|
|
2164
|
-
{
|
|
2165
|
-
"name": "file-size-limit-bytes",
|
|
2166
|
-
"default": "DEFAULT_FILE_SIZE_LIMIT",
|
|
2167
|
-
"resolveInitializer": {
|
|
2168
|
-
"module": "src/_common/base-file-component.ts"
|
|
2169
|
-
},
|
|
2170
|
-
"fieldName": "fileSizeLimitBytes"
|
|
2171
|
-
}
|
|
2172
|
-
],
|
|
2173
|
-
"superclass": {
|
|
2174
|
-
"name": "FoundationElement",
|
|
2175
|
-
"package": "@microsoft/fast-foundation"
|
|
2176
|
-
}
|
|
2177
|
-
}
|
|
2178
|
-
],
|
|
2179
|
-
"exports": [
|
|
2180
|
-
{
|
|
2181
|
-
"kind": "js",
|
|
2182
|
-
"name": "BaseFileComponent",
|
|
2183
|
-
"declaration": {
|
|
2184
|
-
"name": "BaseFileComponent",
|
|
2185
|
-
"module": "src/_common/base-file-component.ts"
|
|
2186
|
-
}
|
|
2187
|
-
}
|
|
2188
|
-
]
|
|
2189
|
-
},
|
|
2190
|
-
{
|
|
2191
|
-
"kind": "javascript-module",
|
|
2192
|
-
"path": "src/_common/icons.ts",
|
|
2193
|
-
"declarations": [
|
|
2194
|
-
{
|
|
2195
|
-
"kind": "function",
|
|
2196
|
-
"name": "closeIcon",
|
|
2197
|
-
"parameters": [
|
|
2198
|
-
{
|
|
2199
|
-
"name": "slot",
|
|
2200
|
-
"default": "'start'"
|
|
2201
|
-
},
|
|
2202
|
-
{
|
|
2203
|
-
"name": "fill",
|
|
2204
|
-
"default": "'#879ba6'"
|
|
2205
|
-
}
|
|
2206
|
-
]
|
|
2207
|
-
}
|
|
2208
|
-
],
|
|
2209
|
-
"exports": [
|
|
2210
|
-
{
|
|
2211
|
-
"kind": "js",
|
|
2212
|
-
"name": "closeIcon",
|
|
2213
|
-
"declaration": {
|
|
2214
|
-
"name": "closeIcon",
|
|
2215
|
-
"module": "src/_common/icons.ts"
|
|
2216
|
-
}
|
|
2217
|
-
}
|
|
2218
|
-
]
|
|
2219
|
-
},
|
|
2220
|
-
{
|
|
2221
|
-
"kind": "javascript-module",
|
|
2222
|
-
"path": "src/_common/index.ts",
|
|
2223
|
-
"declarations": [],
|
|
2224
|
-
"exports": [
|
|
2225
|
-
{
|
|
2226
|
-
"kind": "js",
|
|
2227
|
-
"name": "*",
|
|
2228
|
-
"declaration": {
|
|
2229
|
-
"name": "*",
|
|
2230
|
-
"package": "./base-file-component"
|
|
2231
|
-
}
|
|
2232
|
-
},
|
|
2233
|
-
{
|
|
2234
|
-
"kind": "js",
|
|
2235
|
-
"name": "*",
|
|
2236
|
-
"declaration": {
|
|
2237
|
-
"name": "*",
|
|
2238
|
-
"package": "./icons"
|
|
2239
|
-
}
|
|
2240
|
-
}
|
|
2241
|
-
]
|
|
2242
|
-
},
|
|
2243
1880
|
{
|
|
2244
1881
|
"kind": "javascript-module",
|
|
2245
1882
|
"path": "src/ai-criteria-search/ai-criteria-search.styles.ts",
|
|
@@ -3220,6 +2857,369 @@
|
|
|
3220
2857
|
}
|
|
3221
2858
|
]
|
|
3222
2859
|
},
|
|
2860
|
+
{
|
|
2861
|
+
"kind": "javascript-module",
|
|
2862
|
+
"path": "src/_common/base-file-component.ts",
|
|
2863
|
+
"declarations": [
|
|
2864
|
+
{
|
|
2865
|
+
"kind": "class",
|
|
2866
|
+
"description": "Abstract base class for file handling components\nProvides common functionality for file selection, validation, and UI state management",
|
|
2867
|
+
"name": "BaseFileComponent",
|
|
2868
|
+
"members": [
|
|
2869
|
+
{
|
|
2870
|
+
"kind": "field",
|
|
2871
|
+
"name": "fileInput",
|
|
2872
|
+
"type": {
|
|
2873
|
+
"text": "HTMLInputElement"
|
|
2874
|
+
},
|
|
2875
|
+
"privacy": "public"
|
|
2876
|
+
},
|
|
2877
|
+
{
|
|
2878
|
+
"kind": "field",
|
|
2879
|
+
"name": "selectedFile",
|
|
2880
|
+
"type": {
|
|
2881
|
+
"text": "File | null"
|
|
2882
|
+
},
|
|
2883
|
+
"privacy": "protected",
|
|
2884
|
+
"default": "null"
|
|
2885
|
+
},
|
|
2886
|
+
{
|
|
2887
|
+
"kind": "field",
|
|
2888
|
+
"name": "label",
|
|
2889
|
+
"type": {
|
|
2890
|
+
"text": "string"
|
|
2891
|
+
}
|
|
2892
|
+
},
|
|
2893
|
+
{
|
|
2894
|
+
"kind": "field",
|
|
2895
|
+
"name": "accept",
|
|
2896
|
+
"type": {
|
|
2897
|
+
"text": "string"
|
|
2898
|
+
},
|
|
2899
|
+
"default": "''"
|
|
2900
|
+
},
|
|
2901
|
+
{
|
|
2902
|
+
"kind": "field",
|
|
2903
|
+
"name": "fileSizeLimitBytes",
|
|
2904
|
+
"default": "10_485_760",
|
|
2905
|
+
"type": {
|
|
2906
|
+
"text": "number"
|
|
2907
|
+
}
|
|
2908
|
+
},
|
|
2909
|
+
{
|
|
2910
|
+
"kind": "field",
|
|
2911
|
+
"name": "fileName",
|
|
2912
|
+
"type": {
|
|
2913
|
+
"text": "string"
|
|
2914
|
+
},
|
|
2915
|
+
"default": "''"
|
|
2916
|
+
},
|
|
2917
|
+
{
|
|
2918
|
+
"kind": "field",
|
|
2919
|
+
"name": "isProcessing",
|
|
2920
|
+
"type": {
|
|
2921
|
+
"text": "boolean"
|
|
2922
|
+
},
|
|
2923
|
+
"default": "false"
|
|
2924
|
+
},
|
|
2925
|
+
{
|
|
2926
|
+
"kind": "method",
|
|
2927
|
+
"name": "handleClick",
|
|
2928
|
+
"privacy": "public",
|
|
2929
|
+
"description": "Opens the file picker dialog\nClears any previous file selection before opening"
|
|
2930
|
+
},
|
|
2931
|
+
{
|
|
2932
|
+
"kind": "method",
|
|
2933
|
+
"name": "onInputChange",
|
|
2934
|
+
"privacy": "public",
|
|
2935
|
+
"parameters": [
|
|
2936
|
+
{
|
|
2937
|
+
"name": "e",
|
|
2938
|
+
"type": {
|
|
2939
|
+
"text": "Event"
|
|
2940
|
+
},
|
|
2941
|
+
"description": "The change event from the file input"
|
|
2942
|
+
}
|
|
2943
|
+
],
|
|
2944
|
+
"description": "Handles file selection from the file input\nValidates file size and sets up for processing"
|
|
2945
|
+
},
|
|
2946
|
+
{
|
|
2947
|
+
"kind": "method",
|
|
2948
|
+
"name": "clearSelection",
|
|
2949
|
+
"privacy": "public",
|
|
2950
|
+
"description": "Clears all file selection and processing state\nResets the component to its initial state"
|
|
2951
|
+
},
|
|
2952
|
+
{
|
|
2953
|
+
"kind": "method",
|
|
2954
|
+
"name": "getSelectedFile",
|
|
2955
|
+
"privacy": "public",
|
|
2956
|
+
"description": "Gets the currently selected file object",
|
|
2957
|
+
"return": {
|
|
2958
|
+
"type": {
|
|
2959
|
+
"text": ""
|
|
2960
|
+
}
|
|
2961
|
+
}
|
|
2962
|
+
},
|
|
2963
|
+
{
|
|
2964
|
+
"kind": "method",
|
|
2965
|
+
"name": "showError",
|
|
2966
|
+
"privacy": "protected",
|
|
2967
|
+
"parameters": [
|
|
2968
|
+
{
|
|
2969
|
+
"name": "title",
|
|
2970
|
+
"type": {
|
|
2971
|
+
"text": "string"
|
|
2972
|
+
},
|
|
2973
|
+
"description": "The error title"
|
|
2974
|
+
},
|
|
2975
|
+
{
|
|
2976
|
+
"name": "message",
|
|
2977
|
+
"type": {
|
|
2978
|
+
"text": "string"
|
|
2979
|
+
},
|
|
2980
|
+
"description": "The error message"
|
|
2981
|
+
}
|
|
2982
|
+
],
|
|
2983
|
+
"description": "Shows an error notification using the unified error handling system"
|
|
2984
|
+
},
|
|
2985
|
+
{
|
|
2986
|
+
"kind": "method",
|
|
2987
|
+
"name": "onFileSelected",
|
|
2988
|
+
"privacy": "protected",
|
|
2989
|
+
"return": {
|
|
2990
|
+
"type": {
|
|
2991
|
+
"text": "void"
|
|
2992
|
+
}
|
|
2993
|
+
},
|
|
2994
|
+
"parameters": [
|
|
2995
|
+
{
|
|
2996
|
+
"name": "files",
|
|
2997
|
+
"type": {
|
|
2998
|
+
"text": "File[]"
|
|
2999
|
+
},
|
|
3000
|
+
"description": "The selected file"
|
|
3001
|
+
}
|
|
3002
|
+
],
|
|
3003
|
+
"description": "Abstract method called when a file is selected"
|
|
3004
|
+
},
|
|
3005
|
+
{
|
|
3006
|
+
"kind": "method",
|
|
3007
|
+
"name": "onFileCleared",
|
|
3008
|
+
"privacy": "protected",
|
|
3009
|
+
"return": {
|
|
3010
|
+
"type": {
|
|
3011
|
+
"text": "void"
|
|
3012
|
+
}
|
|
3013
|
+
},
|
|
3014
|
+
"description": "Abstract method called when file selection is cleared"
|
|
3015
|
+
},
|
|
3016
|
+
{
|
|
3017
|
+
"kind": "field",
|
|
3018
|
+
"name": "_presentation",
|
|
3019
|
+
"type": {
|
|
3020
|
+
"text": "ComponentPresentation | null | undefined"
|
|
3021
|
+
},
|
|
3022
|
+
"privacy": "private",
|
|
3023
|
+
"default": "void 0",
|
|
3024
|
+
"inheritedFrom": {
|
|
3025
|
+
"name": "FoundationElement",
|
|
3026
|
+
"module": "src/foundation-element/foundation-element.ts"
|
|
3027
|
+
}
|
|
3028
|
+
},
|
|
3029
|
+
{
|
|
3030
|
+
"kind": "field",
|
|
3031
|
+
"name": "$presentation",
|
|
3032
|
+
"type": {
|
|
3033
|
+
"text": "ComponentPresentation | null"
|
|
3034
|
+
},
|
|
3035
|
+
"privacy": "public",
|
|
3036
|
+
"description": "A property which resolves the ComponentPresentation instance\nfor the current component.",
|
|
3037
|
+
"inheritedFrom": {
|
|
3038
|
+
"name": "FoundationElement",
|
|
3039
|
+
"module": "src/foundation-element/foundation-element.ts"
|
|
3040
|
+
}
|
|
3041
|
+
},
|
|
3042
|
+
{
|
|
3043
|
+
"kind": "field",
|
|
3044
|
+
"name": "template",
|
|
3045
|
+
"type": {
|
|
3046
|
+
"text": "ElementViewTemplate | void | null"
|
|
3047
|
+
},
|
|
3048
|
+
"privacy": "public",
|
|
3049
|
+
"description": "Sets the template of the element instance. When undefined,\nthe element will attempt to resolve the template from\nthe associated presentation or custom element definition.",
|
|
3050
|
+
"inheritedFrom": {
|
|
3051
|
+
"name": "FoundationElement",
|
|
3052
|
+
"module": "src/foundation-element/foundation-element.ts"
|
|
3053
|
+
}
|
|
3054
|
+
},
|
|
3055
|
+
{
|
|
3056
|
+
"kind": "method",
|
|
3057
|
+
"name": "templateChanged",
|
|
3058
|
+
"privacy": "protected",
|
|
3059
|
+
"return": {
|
|
3060
|
+
"type": {
|
|
3061
|
+
"text": "void"
|
|
3062
|
+
}
|
|
3063
|
+
},
|
|
3064
|
+
"inheritedFrom": {
|
|
3065
|
+
"name": "FoundationElement",
|
|
3066
|
+
"module": "src/foundation-element/foundation-element.ts"
|
|
3067
|
+
}
|
|
3068
|
+
},
|
|
3069
|
+
{
|
|
3070
|
+
"kind": "field",
|
|
3071
|
+
"name": "styles",
|
|
3072
|
+
"type": {
|
|
3073
|
+
"text": "ElementStyles | void | null"
|
|
3074
|
+
},
|
|
3075
|
+
"privacy": "public",
|
|
3076
|
+
"description": "Sets the default styles for the element instance. When undefined,\nthe element will attempt to resolve default styles from\nthe associated presentation or custom element definition.",
|
|
3077
|
+
"inheritedFrom": {
|
|
3078
|
+
"name": "FoundationElement",
|
|
3079
|
+
"module": "src/foundation-element/foundation-element.ts"
|
|
3080
|
+
}
|
|
3081
|
+
},
|
|
3082
|
+
{
|
|
3083
|
+
"kind": "method",
|
|
3084
|
+
"name": "stylesChanged",
|
|
3085
|
+
"privacy": "protected",
|
|
3086
|
+
"return": {
|
|
3087
|
+
"type": {
|
|
3088
|
+
"text": "void"
|
|
3089
|
+
}
|
|
3090
|
+
},
|
|
3091
|
+
"inheritedFrom": {
|
|
3092
|
+
"name": "FoundationElement",
|
|
3093
|
+
"module": "src/foundation-element/foundation-element.ts"
|
|
3094
|
+
}
|
|
3095
|
+
},
|
|
3096
|
+
{
|
|
3097
|
+
"kind": "method",
|
|
3098
|
+
"name": "compose",
|
|
3099
|
+
"privacy": "public",
|
|
3100
|
+
"static": true,
|
|
3101
|
+
"return": {
|
|
3102
|
+
"type": {
|
|
3103
|
+
"text": "(\n overrideDefinition?: OverrideFoundationElementDefinition<T>\n ) => FoundationElementRegistry<T, K>"
|
|
3104
|
+
}
|
|
3105
|
+
},
|
|
3106
|
+
"parameters": [
|
|
3107
|
+
{
|
|
3108
|
+
"name": "this",
|
|
3109
|
+
"type": {
|
|
3110
|
+
"text": "K"
|
|
3111
|
+
}
|
|
3112
|
+
},
|
|
3113
|
+
{
|
|
3114
|
+
"name": "elementDefinition",
|
|
3115
|
+
"type": {
|
|
3116
|
+
"text": "T"
|
|
3117
|
+
},
|
|
3118
|
+
"description": "The definition of the element to create the registry\nfunction for."
|
|
3119
|
+
}
|
|
3120
|
+
],
|
|
3121
|
+
"description": "Defines an element registry function with a set of element definition defaults.",
|
|
3122
|
+
"inheritedFrom": {
|
|
3123
|
+
"name": "FoundationElement",
|
|
3124
|
+
"module": "src/foundation-element/foundation-element.ts"
|
|
3125
|
+
}
|
|
3126
|
+
}
|
|
3127
|
+
],
|
|
3128
|
+
"attributes": [
|
|
3129
|
+
{
|
|
3130
|
+
"name": "label",
|
|
3131
|
+
"type": {
|
|
3132
|
+
"text": "string"
|
|
3133
|
+
},
|
|
3134
|
+
"fieldName": "label"
|
|
3135
|
+
},
|
|
3136
|
+
{
|
|
3137
|
+
"name": "accept",
|
|
3138
|
+
"type": {
|
|
3139
|
+
"text": "string"
|
|
3140
|
+
},
|
|
3141
|
+
"default": "''",
|
|
3142
|
+
"fieldName": "accept"
|
|
3143
|
+
},
|
|
3144
|
+
{
|
|
3145
|
+
"name": "file-size-limit-bytes",
|
|
3146
|
+
"default": "DEFAULT_FILE_SIZE_LIMIT",
|
|
3147
|
+
"resolveInitializer": {
|
|
3148
|
+
"module": "src/_common/base-file-component.ts"
|
|
3149
|
+
},
|
|
3150
|
+
"fieldName": "fileSizeLimitBytes"
|
|
3151
|
+
}
|
|
3152
|
+
],
|
|
3153
|
+
"superclass": {
|
|
3154
|
+
"name": "FoundationElement",
|
|
3155
|
+
"package": "@microsoft/fast-foundation"
|
|
3156
|
+
}
|
|
3157
|
+
}
|
|
3158
|
+
],
|
|
3159
|
+
"exports": [
|
|
3160
|
+
{
|
|
3161
|
+
"kind": "js",
|
|
3162
|
+
"name": "BaseFileComponent",
|
|
3163
|
+
"declaration": {
|
|
3164
|
+
"name": "BaseFileComponent",
|
|
3165
|
+
"module": "src/_common/base-file-component.ts"
|
|
3166
|
+
}
|
|
3167
|
+
}
|
|
3168
|
+
]
|
|
3169
|
+
},
|
|
3170
|
+
{
|
|
3171
|
+
"kind": "javascript-module",
|
|
3172
|
+
"path": "src/_common/icons.ts",
|
|
3173
|
+
"declarations": [
|
|
3174
|
+
{
|
|
3175
|
+
"kind": "function",
|
|
3176
|
+
"name": "closeIcon",
|
|
3177
|
+
"parameters": [
|
|
3178
|
+
{
|
|
3179
|
+
"name": "slot",
|
|
3180
|
+
"default": "'start'"
|
|
3181
|
+
},
|
|
3182
|
+
{
|
|
3183
|
+
"name": "fill",
|
|
3184
|
+
"default": "'#879ba6'"
|
|
3185
|
+
}
|
|
3186
|
+
]
|
|
3187
|
+
}
|
|
3188
|
+
],
|
|
3189
|
+
"exports": [
|
|
3190
|
+
{
|
|
3191
|
+
"kind": "js",
|
|
3192
|
+
"name": "closeIcon",
|
|
3193
|
+
"declaration": {
|
|
3194
|
+
"name": "closeIcon",
|
|
3195
|
+
"module": "src/_common/icons.ts"
|
|
3196
|
+
}
|
|
3197
|
+
}
|
|
3198
|
+
]
|
|
3199
|
+
},
|
|
3200
|
+
{
|
|
3201
|
+
"kind": "javascript-module",
|
|
3202
|
+
"path": "src/_common/index.ts",
|
|
3203
|
+
"declarations": [],
|
|
3204
|
+
"exports": [
|
|
3205
|
+
{
|
|
3206
|
+
"kind": "js",
|
|
3207
|
+
"name": "*",
|
|
3208
|
+
"declaration": {
|
|
3209
|
+
"name": "*",
|
|
3210
|
+
"package": "./base-file-component"
|
|
3211
|
+
}
|
|
3212
|
+
},
|
|
3213
|
+
{
|
|
3214
|
+
"kind": "js",
|
|
3215
|
+
"name": "*",
|
|
3216
|
+
"declaration": {
|
|
3217
|
+
"name": "*",
|
|
3218
|
+
"package": "./icons"
|
|
3219
|
+
}
|
|
3220
|
+
}
|
|
3221
|
+
]
|
|
3222
|
+
},
|
|
3223
3223
|
{
|
|
3224
3224
|
"kind": "javascript-module",
|
|
3225
3225
|
"path": "src/_config/index.ts",
|
|
@@ -45408,11 +45408,40 @@
|
|
|
45408
45408
|
"default": "'second'",
|
|
45409
45409
|
"attribute": "date-countdown-unit"
|
|
45410
45410
|
},
|
|
45411
|
+
{
|
|
45412
|
+
"kind": "field",
|
|
45413
|
+
"name": "dateCountdownVisibleAfter",
|
|
45414
|
+
"type": {
|
|
45415
|
+
"text": "number"
|
|
45416
|
+
},
|
|
45417
|
+
"attribute": "date-countdown-visible-after"
|
|
45418
|
+
},
|
|
45419
|
+
{
|
|
45420
|
+
"kind": "field",
|
|
45421
|
+
"name": "hideWhenCountdownCompleted",
|
|
45422
|
+
"type": {
|
|
45423
|
+
"text": "boolean"
|
|
45424
|
+
},
|
|
45425
|
+
"default": "false",
|
|
45426
|
+
"attribute": "hide-when-countdown-completed"
|
|
45427
|
+
},
|
|
45411
45428
|
{
|
|
45412
45429
|
"kind": "field",
|
|
45413
45430
|
"name": "dateInterval",
|
|
45414
45431
|
"privacy": "private"
|
|
45415
45432
|
},
|
|
45433
|
+
{
|
|
45434
|
+
"kind": "method",
|
|
45435
|
+
"name": "dateCountdownVisibleAfterChanged",
|
|
45436
|
+
"parameters": [
|
|
45437
|
+
{
|
|
45438
|
+
"name": "oldValue"
|
|
45439
|
+
},
|
|
45440
|
+
{
|
|
45441
|
+
"name": "newValue"
|
|
45442
|
+
}
|
|
45443
|
+
]
|
|
45444
|
+
},
|
|
45416
45445
|
{
|
|
45417
45446
|
"kind": "method",
|
|
45418
45447
|
"name": "setUpDateCountdown",
|
|
@@ -45444,6 +45473,11 @@
|
|
|
45444
45473
|
}
|
|
45445
45474
|
]
|
|
45446
45475
|
},
|
|
45476
|
+
{
|
|
45477
|
+
"kind": "method",
|
|
45478
|
+
"name": "updateVisibilityFromStartTime",
|
|
45479
|
+
"privacy": "private"
|
|
45480
|
+
},
|
|
45447
45481
|
{
|
|
45448
45482
|
"kind": "method",
|
|
45449
45483
|
"name": "clearCountdownTimer",
|
|
@@ -45645,6 +45679,23 @@
|
|
|
45645
45679
|
"fieldName": "dateCountdownUnit",
|
|
45646
45680
|
"description": "the minimum unit of time shown in the countdown. Defaults to 'seconds'"
|
|
45647
45681
|
},
|
|
45682
|
+
{
|
|
45683
|
+
"name": "date-countdown-visible-after",
|
|
45684
|
+
"type": {
|
|
45685
|
+
"text": "number"
|
|
45686
|
+
},
|
|
45687
|
+
"fieldName": "dateCountdownVisibleAfter",
|
|
45688
|
+
"description": "a timestamp (in milliseconds) that controls when the countdown (and pill) becomes visible. If present, the pill will only be shown once the current time is equal to or after this timestamp."
|
|
45689
|
+
},
|
|
45690
|
+
{
|
|
45691
|
+
"name": "hide-when-countdown-completed",
|
|
45692
|
+
"type": {
|
|
45693
|
+
"text": "boolean"
|
|
45694
|
+
},
|
|
45695
|
+
"default": "false",
|
|
45696
|
+
"fieldName": "hideWhenCountdownCompleted",
|
|
45697
|
+
"description": "if true, the status pill will be removed from the template once the countdown has expired."
|
|
45698
|
+
},
|
|
45648
45699
|
{
|
|
45649
45700
|
"name": "background-color",
|
|
45650
45701
|
"type": {
|
|
@@ -45735,6 +45786,23 @@
|
|
|
45735
45786
|
"default": "'second'",
|
|
45736
45787
|
"attribute": "date-countdown-unit",
|
|
45737
45788
|
"fieldName": "dateCountdownUnit"
|
|
45789
|
+
},
|
|
45790
|
+
{
|
|
45791
|
+
"name": "date-countdown-visible-after",
|
|
45792
|
+
"type": {
|
|
45793
|
+
"text": "number"
|
|
45794
|
+
},
|
|
45795
|
+
"attribute": "date-countdown-visible-after",
|
|
45796
|
+
"fieldName": "dateCountdownVisibleAfter"
|
|
45797
|
+
},
|
|
45798
|
+
{
|
|
45799
|
+
"name": "hide-when-countdown-completed",
|
|
45800
|
+
"type": {
|
|
45801
|
+
"text": "boolean"
|
|
45802
|
+
},
|
|
45803
|
+
"default": "false",
|
|
45804
|
+
"attribute": "hide-when-countdown-completed",
|
|
45805
|
+
"fieldName": "hideWhenCountdownCompleted"
|
|
45738
45806
|
}
|
|
45739
45807
|
],
|
|
45740
45808
|
"superclass": {
|
|
@@ -122,18 +122,51 @@ export declare class StatusPill extends FoundationElement {
|
|
|
122
122
|
* ```
|
|
123
123
|
*/
|
|
124
124
|
dateCountdownUnit: CountdownUnit;
|
|
125
|
+
/**
|
|
126
|
+
* @attr date-countdown-visible-after - a timestamp (in milliseconds) that controls
|
|
127
|
+
* when the countdown (and pill) becomes visible. If present, the pill will only
|
|
128
|
+
* be shown once the current time is equal to or after this timestamp.
|
|
129
|
+
* @example
|
|
130
|
+
* Show pill and countdown only after a specific start time
|
|
131
|
+
* ```html
|
|
132
|
+
* <rapid-status-pill
|
|
133
|
+
* date-countdown="1750955880385"
|
|
134
|
+
* date-countdown-visible-after="1750952280385"
|
|
135
|
+
* ></rapid-status-pill>
|
|
136
|
+
* ```
|
|
137
|
+
*/
|
|
138
|
+
dateCountdownVisibleAfter: number;
|
|
139
|
+
/**
|
|
140
|
+
* @attr hide-when-countdown-completed - if true, the status pill will be removed
|
|
141
|
+
* from the template once the countdown has expired.
|
|
142
|
+
*/
|
|
143
|
+
hideWhenCountdownCompleted: boolean;
|
|
125
144
|
/**
|
|
126
145
|
* @internal
|
|
127
146
|
*/
|
|
128
147
|
countdown: string;
|
|
148
|
+
/**
|
|
149
|
+
* @internal
|
|
150
|
+
* Tracks whether the countdown has reached or passed its target.
|
|
151
|
+
*/
|
|
152
|
+
isCountdownExpired: boolean;
|
|
153
|
+
/**
|
|
154
|
+
* @internal
|
|
155
|
+
* Controls whether the pill should be rendered based on the optional
|
|
156
|
+
* date-countdown-visible-after start time.
|
|
157
|
+
*/
|
|
158
|
+
isCountdownVisible: boolean;
|
|
129
159
|
private dateInterval;
|
|
130
160
|
/**
|
|
131
161
|
* @internal
|
|
132
162
|
*/
|
|
133
163
|
dateCountdownChanged(oldValue: any, newValue: any): void;
|
|
164
|
+
dateCountdownVisibleAfterChanged(oldValue: any, newValue: any): void;
|
|
165
|
+
connectedCallback(): void;
|
|
134
166
|
disconnectedCallback(): void;
|
|
135
167
|
private setUpDateCountdown;
|
|
136
168
|
private updateCountdown;
|
|
169
|
+
private updateVisibilityFromStartTime;
|
|
137
170
|
private clearCountdownTimer;
|
|
138
171
|
}
|
|
139
172
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"status-pill.d.ts","sourceRoot":"","sources":["../../../src/status-pill/status-pill.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,iBAAiB,EAAE,MAAM,4BAA4B,CAAC;AAU/D;;;GAGG;AACH,MAAM,MAAM,aAAa,GAAG,MAAM,GAAG,QAAQ,GAAG,QAAQ,CAAC;AAEzD;;GAEG;AACH,eAAO,MAAM,sBAAsB,GACjC,mBAAmB,MAAM,EACzB,UAAS,aAAwB,KAChC,MAoCF,CAAC;AAEF;;GAEG;AACH,qBAAa,UAAW,SAAQ,iBAAiB;IAC/C;;;;;;;;OAQG;IACsC,eAAe,EAAE,MAAM,CAAC;IAEjE;;;;;;;;OAQG;IAC+B,QAAQ,EAAE,MAAM,CAAC;IAEnD;;;;;;;;OAQG;IAC8B,OAAO,EAAE,MAAM,CAAC;IAEjD;;;;;;;;OAQG;IACkC,WAAW,EAAE,MAAM,CAAC;IAEzD;;;;;;;;OAQG;IACmD,0BAA0B,EAAE,MAAM,CAAC;IAEzF;;;;;;;;OAQG;IAC+B,QAAQ,EAAE,MAAM,CAAQ;IAE1D;;;;;;;;OAQG;IACgC,SAAS,EAAE,MAAM,CAAC;IAErD;;;;;;;;OAQG;IACG,IAAI,EAAE,MAAM,CAAC;IAEnB;;;;;;;;OAQG;IACoC,aAAa,EAAE,MAAM,CAAC;IAE7D;;;;;;;;OAQG;IACsD,6BAA6B,EAAE,MAAM,CAClF;IAEZ;;;;;;;;OAQG;IACyC,iBAAiB,EAAE,aAAa,CAAY;IAExF;;OAEG;IACS,SAAS,EAAE,MAAM,CAAC;IAE9B,OAAO,CAAC,YAAY,CAAC;IAErB;;OAEG;IACH,oBAAoB,CAAC,QAAQ,KAAA,EAAE,QAAQ,KAAA;
|
|
1
|
+
{"version":3,"file":"status-pill.d.ts","sourceRoot":"","sources":["../../../src/status-pill/status-pill.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,iBAAiB,EAAE,MAAM,4BAA4B,CAAC;AAU/D;;;GAGG;AACH,MAAM,MAAM,aAAa,GAAG,MAAM,GAAG,QAAQ,GAAG,QAAQ,CAAC;AAEzD;;GAEG;AACH,eAAO,MAAM,sBAAsB,GACjC,mBAAmB,MAAM,EACzB,UAAS,aAAwB,KAChC,MAoCF,CAAC;AAEF;;GAEG;AACH,qBAAa,UAAW,SAAQ,iBAAiB;IAC/C;;;;;;;;OAQG;IACsC,eAAe,EAAE,MAAM,CAAC;IAEjE;;;;;;;;OAQG;IAC+B,QAAQ,EAAE,MAAM,CAAC;IAEnD;;;;;;;;OAQG;IAC8B,OAAO,EAAE,MAAM,CAAC;IAEjD;;;;;;;;OAQG;IACkC,WAAW,EAAE,MAAM,CAAC;IAEzD;;;;;;;;OAQG;IACmD,0BAA0B,EAAE,MAAM,CAAC;IAEzF;;;;;;;;OAQG;IAC+B,QAAQ,EAAE,MAAM,CAAQ;IAE1D;;;;;;;;OAQG;IACgC,SAAS,EAAE,MAAM,CAAC;IAErD;;;;;;;;OAQG;IACG,IAAI,EAAE,MAAM,CAAC;IAEnB;;;;;;;;OAQG;IACoC,aAAa,EAAE,MAAM,CAAC;IAE7D;;;;;;;;OAQG;IACsD,6BAA6B,EAAE,MAAM,CAClF;IAEZ;;;;;;;;OAQG;IACyC,iBAAiB,EAAE,aAAa,CAAY;IAExF;;;;;;;;;;;;OAYG;IACkD,yBAAyB,EAAE,MAAM,CAAC;IAEvF;;;OAGG;IAEH,0BAA0B,EAAE,OAAO,CAAS;IAE5C;;OAEG;IACS,SAAS,EAAE,MAAM,CAAC;IAE9B;;;OAGG;IACS,kBAAkB,EAAE,OAAO,CAAS;IAEhD;;;;OAIG;IACS,kBAAkB,EAAE,OAAO,CAAQ;IAE/C,OAAO,CAAC,YAAY,CAAC;IAErB;;OAEG;IACH,oBAAoB,CAAC,QAAQ,KAAA,EAAE,QAAQ,KAAA;IAYvC,gCAAgC,CAAC,QAAQ,KAAA,EAAE,QAAQ,KAAA;IAMnD,iBAAiB;IAKjB,oBAAoB;IAKpB,OAAO,CAAC,kBAAkB;IAa1B,OAAO,CAAC,eAAe;IAgCvB,OAAO,CAAC,6BAA6B;IAcrC,OAAO,CAAC,mBAAmB;CAO5B;AAED;;;;;;GAMG;AACH,eAAO,MAAM,oBAAoB;;;;;;;;qBAI/B,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"status-pill.template.d.ts","sourceRoot":"","sources":["../../../src/status-pill/status-pill.template.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;
|
|
1
|
+
{"version":3,"file":"status-pill.template.d.ts","sourceRoot":"","sources":["../../../src/status-pill/status-pill.template.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAiDhD,eAAO,MAAM,4BAA4B,iEAExC,CAAC"}
|
|
@@ -85,6 +85,22 @@ export class StatusPill extends FoundationElement {
|
|
|
85
85
|
* ```
|
|
86
86
|
*/
|
|
87
87
|
this.dateCountdownUnit = 'second';
|
|
88
|
+
/**
|
|
89
|
+
* @attr hide-when-countdown-completed - if true, the status pill will be removed
|
|
90
|
+
* from the template once the countdown has expired.
|
|
91
|
+
*/
|
|
92
|
+
this.hideWhenCountdownCompleted = false;
|
|
93
|
+
/**
|
|
94
|
+
* @internal
|
|
95
|
+
* Tracks whether the countdown has reached or passed its target.
|
|
96
|
+
*/
|
|
97
|
+
this.isCountdownExpired = false;
|
|
98
|
+
/**
|
|
99
|
+
* @internal
|
|
100
|
+
* Controls whether the pill should be rendered based on the optional
|
|
101
|
+
* date-countdown-visible-after start time.
|
|
102
|
+
*/
|
|
103
|
+
this.isCountdownVisible = true;
|
|
88
104
|
}
|
|
89
105
|
/**
|
|
90
106
|
* @internal
|
|
@@ -95,9 +111,19 @@ export class StatusPill extends FoundationElement {
|
|
|
95
111
|
this.clearCountdownTimer();
|
|
96
112
|
return;
|
|
97
113
|
}
|
|
114
|
+
this.isCountdownExpired = false;
|
|
98
115
|
this.setUpDateCountdown(newValue);
|
|
99
116
|
}
|
|
100
117
|
}
|
|
118
|
+
dateCountdownVisibleAfterChanged(oldValue, newValue) {
|
|
119
|
+
if (oldValue !== newValue) {
|
|
120
|
+
this.updateVisibilityFromStartTime();
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
connectedCallback() {
|
|
124
|
+
this.updateVisibilityFromStartTime();
|
|
125
|
+
super.connectedCallback();
|
|
126
|
+
}
|
|
101
127
|
disconnectedCallback() {
|
|
102
128
|
this.clearCountdownTimer();
|
|
103
129
|
super.disconnectedCallback();
|
|
@@ -117,20 +143,49 @@ export class StatusPill extends FoundationElement {
|
|
|
117
143
|
updateCountdown(targetDate) {
|
|
118
144
|
const now = new Date().getTime();
|
|
119
145
|
const diff = Math.floor(targetDate.getTime() - now);
|
|
146
|
+
const visibleAfterMs = this.dateCountdownVisibleAfter !== undefined && this.dateCountdownVisibleAfter !== null
|
|
147
|
+
? Number(this.dateCountdownVisibleAfter)
|
|
148
|
+
: undefined;
|
|
149
|
+
if (visibleAfterMs !== undefined && !isNaN(visibleAfterMs) && now < visibleAfterMs) {
|
|
150
|
+
// Not yet reached the start time; hide the entire pill/countdown.
|
|
151
|
+
this.isCountdownVisible = false;
|
|
152
|
+
this.countdown = null;
|
|
153
|
+
this.isCountdownExpired = false;
|
|
154
|
+
return;
|
|
155
|
+
}
|
|
156
|
+
this.isCountdownVisible = true;
|
|
120
157
|
if (diff <= 0) {
|
|
121
|
-
this.
|
|
122
|
-
|
|
158
|
+
if (this.hideWhenCountdownCompleted) {
|
|
159
|
+
this.isCountdownExpired = true;
|
|
160
|
+
this.clearCountdownTimer();
|
|
161
|
+
}
|
|
162
|
+
else {
|
|
163
|
+
this.countdown = this.dateCountdownCompletedMessage;
|
|
164
|
+
clearInterval(this.dateInterval);
|
|
165
|
+
}
|
|
123
166
|
}
|
|
124
167
|
else {
|
|
125
168
|
this.countdown = formatTimeForCountDown(diff, this.dateCountdownUnit);
|
|
126
169
|
}
|
|
127
170
|
}
|
|
171
|
+
updateVisibilityFromStartTime() {
|
|
172
|
+
const visibleAfterMs = this.dateCountdownVisibleAfter !== undefined && this.dateCountdownVisibleAfter !== null
|
|
173
|
+
? Number(this.dateCountdownVisibleAfter)
|
|
174
|
+
: undefined;
|
|
175
|
+
if (visibleAfterMs !== undefined && !isNaN(visibleAfterMs)) {
|
|
176
|
+
const now = Date.now();
|
|
177
|
+
this.isCountdownVisible = now >= visibleAfterMs;
|
|
178
|
+
}
|
|
179
|
+
else {
|
|
180
|
+
this.isCountdownVisible = true;
|
|
181
|
+
}
|
|
182
|
+
}
|
|
128
183
|
clearCountdownTimer() {
|
|
129
184
|
if (this.dateInterval) {
|
|
130
185
|
clearInterval(this.dateInterval);
|
|
131
186
|
this.dateInterval = null;
|
|
132
|
-
this.countdown = null;
|
|
133
187
|
}
|
|
188
|
+
this.countdown = null;
|
|
134
189
|
}
|
|
135
190
|
}
|
|
136
191
|
__decorate([
|
|
@@ -166,9 +221,21 @@ __decorate([
|
|
|
166
221
|
__decorate([
|
|
167
222
|
attr({ attribute: 'date-countdown-unit' })
|
|
168
223
|
], StatusPill.prototype, "dateCountdownUnit", void 0);
|
|
224
|
+
__decorate([
|
|
225
|
+
attr({ attribute: 'date-countdown-visible-after' })
|
|
226
|
+
], StatusPill.prototype, "dateCountdownVisibleAfter", void 0);
|
|
227
|
+
__decorate([
|
|
228
|
+
attr({ mode: 'boolean', attribute: 'hide-when-countdown-completed' })
|
|
229
|
+
], StatusPill.prototype, "hideWhenCountdownCompleted", void 0);
|
|
169
230
|
__decorate([
|
|
170
231
|
observable
|
|
171
232
|
], StatusPill.prototype, "countdown", void 0);
|
|
233
|
+
__decorate([
|
|
234
|
+
observable
|
|
235
|
+
], StatusPill.prototype, "isCountdownExpired", void 0);
|
|
236
|
+
__decorate([
|
|
237
|
+
observable
|
|
238
|
+
], StatusPill.prototype, "isCountdownVisible", void 0);
|
|
172
239
|
/**
|
|
173
240
|
* The Foundation Status Pill
|
|
174
241
|
*
|
|
@@ -1,32 +1,34 @@
|
|
|
1
1
|
import { html, when } from '@microsoft/fast-element';
|
|
2
2
|
import { getPrefix } from '../utils';
|
|
3
3
|
const getPrefixedStatusPillTemplate = (prefix) => html `
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
4
|
+
${when((x) => x.isCountdownVisible && !(x.hideWhenCountdownCompleted && x.isCountdownExpired), html `
|
|
5
|
+
<div
|
|
6
|
+
data-test-id="status-pill"
|
|
7
|
+
part="status-pill"
|
|
8
|
+
class="status-pill"
|
|
9
|
+
style="color: ${(x) => x.textColor || ''}; background: ${(x) => x.backgroundColor || ''};"
|
|
10
|
+
>
|
|
11
|
+
${when((x) => x.iconName, html `
|
|
12
|
+
<${prefix}-icon name="${(x) => x.iconName}" size="${(x) => x.iconSize}"></${prefix}-icon>
|
|
13
|
+
`)}
|
|
14
|
+
${when((x) => x.iconSrc, html `
|
|
15
|
+
<img alt="${(x) => x.iconSrc}" class="status-pill-image" src="${(x) => x.iconSrc}" />
|
|
16
|
+
`)}
|
|
17
|
+
${when((x) => x.iconInitial, html `
|
|
18
|
+
<div
|
|
19
|
+
data-test-id="status-pill-initial"
|
|
20
|
+
class="status-pill-initial"
|
|
21
|
+
style="color:${(x) => x.textColor}; background-color: ${(x) => x.iconInitialBackgroundColor}"
|
|
22
|
+
>
|
|
23
|
+
${(x) => x.iconInitial.substring(0, 1)}
|
|
24
|
+
</div>
|
|
25
|
+
`)}
|
|
26
|
+
<span data-test-id="status-pill-text">${(x) => x.text}</span>
|
|
27
|
+
${when((x) => x.countdown, html `
|
|
28
|
+
<span data-test-id="status-pill-countdown">${(x) => x.countdown}</span>
|
|
29
|
+
`)}
|
|
30
|
+
</div>
|
|
31
|
+
`)}
|
|
30
32
|
`;
|
|
31
33
|
export const foundationStatusPillTemplate = html `
|
|
32
34
|
${(x) => getPrefixedStatusPillTemplate(getPrefix(x))}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@genesislcap/foundation-ui",
|
|
3
3
|
"description": "Genesis Foundation UI",
|
|
4
|
-
"version": "14.
|
|
4
|
+
"version": "14.402.0",
|
|
5
5
|
"sideEffects": false,
|
|
6
6
|
"license": "SEE LICENSE IN license.txt",
|
|
7
7
|
"main": "dist/esm/index.js",
|
|
@@ -85,13 +85,13 @@
|
|
|
85
85
|
}
|
|
86
86
|
},
|
|
87
87
|
"devDependencies": {
|
|
88
|
-
"@genesislcap/foundation-testing": "14.
|
|
89
|
-
"@genesislcap/genx": "14.
|
|
90
|
-
"@genesislcap/rollup-builder": "14.
|
|
91
|
-
"@genesislcap/ts-builder": "14.
|
|
92
|
-
"@genesislcap/uvu-playwright-builder": "14.
|
|
93
|
-
"@genesislcap/vite-builder": "14.
|
|
94
|
-
"@genesislcap/webpack-builder": "14.
|
|
88
|
+
"@genesislcap/foundation-testing": "14.402.0",
|
|
89
|
+
"@genesislcap/genx": "14.402.0",
|
|
90
|
+
"@genesislcap/rollup-builder": "14.402.0",
|
|
91
|
+
"@genesislcap/ts-builder": "14.402.0",
|
|
92
|
+
"@genesislcap/uvu-playwright-builder": "14.402.0",
|
|
93
|
+
"@genesislcap/vite-builder": "14.402.0",
|
|
94
|
+
"@genesislcap/webpack-builder": "14.402.0",
|
|
95
95
|
"copyfiles": "^2.4.1"
|
|
96
96
|
},
|
|
97
97
|
"dependencies": {
|
|
@@ -100,16 +100,16 @@
|
|
|
100
100
|
"@fortawesome/free-regular-svg-icons": "^6.2.1",
|
|
101
101
|
"@fortawesome/free-solid-svg-icons": "^6.2.1",
|
|
102
102
|
"@genesiscommunitysuccess/analyzer-import-alias-plugin": "^5.0.3",
|
|
103
|
-
"@genesislcap/expression-builder": "14.
|
|
104
|
-
"@genesislcap/foundation-ai": "14.
|
|
105
|
-
"@genesislcap/foundation-comms": "14.
|
|
106
|
-
"@genesislcap/foundation-criteria": "14.
|
|
107
|
-
"@genesislcap/foundation-errors": "14.
|
|
108
|
-
"@genesislcap/foundation-events": "14.
|
|
109
|
-
"@genesislcap/foundation-logger": "14.
|
|
110
|
-
"@genesislcap/foundation-notifications": "14.
|
|
111
|
-
"@genesislcap/foundation-user": "14.
|
|
112
|
-
"@genesislcap/foundation-utils": "14.
|
|
103
|
+
"@genesislcap/expression-builder": "14.402.0",
|
|
104
|
+
"@genesislcap/foundation-ai": "14.402.0",
|
|
105
|
+
"@genesislcap/foundation-comms": "14.402.0",
|
|
106
|
+
"@genesislcap/foundation-criteria": "14.402.0",
|
|
107
|
+
"@genesislcap/foundation-errors": "14.402.0",
|
|
108
|
+
"@genesislcap/foundation-events": "14.402.0",
|
|
109
|
+
"@genesislcap/foundation-logger": "14.402.0",
|
|
110
|
+
"@genesislcap/foundation-notifications": "14.402.0",
|
|
111
|
+
"@genesislcap/foundation-user": "14.402.0",
|
|
112
|
+
"@genesislcap/foundation-utils": "14.402.0",
|
|
113
113
|
"@microsoft/fast-colors": "5.3.1",
|
|
114
114
|
"@microsoft/fast-components": "2.30.6",
|
|
115
115
|
"@microsoft/fast-element": "1.14.0",
|
|
@@ -131,5 +131,5 @@
|
|
|
131
131
|
"access": "public"
|
|
132
132
|
},
|
|
133
133
|
"customElements": "dist/custom-elements.json",
|
|
134
|
-
"gitHead": "
|
|
134
|
+
"gitHead": "7ffded0edb096db3e60298c0d0a216071aa1d970"
|
|
135
135
|
}
|