@aquera/nile-elements 0.1.40-beta-1.9 → 0.1.40-beta-2.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.
- package/README.md +3 -0
- package/dist/index.js +7 -7
- package/dist/nile-card/nile-card.css.cjs.js +1 -1
- package/dist/nile-card/nile-card.css.cjs.js.map +1 -1
- package/dist/nile-card/nile-card.css.esm.js +1 -1
- package/dist/nile-icon/index.cjs.js +1 -1
- package/dist/nile-icon/index.cjs.js.map +1 -1
- package/dist/nile-icon/index.esm.js +3 -3
- package/dist/nile-icon-button/nile-icon-button.cjs.js +1 -1
- package/dist/nile-icon-button/nile-icon-button.cjs.js.map +1 -1
- package/dist/nile-icon-button/nile-icon-button.esm.js +3 -3
- package/dist/src/nile-card/nile-card.css.js +1 -1
- package/dist/src/nile-card/nile-card.css.js.map +1 -1
- package/dist/src/nile-icon/index.d.ts +0 -1
- package/dist/src/nile-icon/index.js +1 -9
- package/dist/src/nile-icon/index.js.map +1 -1
- package/dist/src/nile-icon-button/nile-icon-button.d.ts +1 -0
- package/dist/src/nile-icon-button/nile-icon-button.js +10 -2
- package/dist/src/nile-icon-button/nile-icon-button.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
- package/src/nile-card/nile-card.css.ts +1 -1
- package/src/nile-icon/index.ts +1 -9
- package/src/nile-icon-button/nile-icon-button.ts +12 -2
- package/vscode-html-custom-data.json +1 -5
package/package.json
CHANGED
@@ -3,7 +3,7 @@
|
|
3
3
|
"description": "Webcomponent nile-elements following open-wc recommendations",
|
4
4
|
"license": "MIT",
|
5
5
|
"author": "nile-elements",
|
6
|
-
"version": "0.1.40-beta-1
|
6
|
+
"version": "0.1.40-beta-2.1",
|
7
7
|
"main": "dist/src/index.js",
|
8
8
|
"type": "module",
|
9
9
|
"module": "dist/src/index.js",
|
@@ -40,7 +40,7 @@ export const styles = css`
|
|
40
40
|
flex-direction: column;
|
41
41
|
justify-items: stretch;
|
42
42
|
background-color: var(--nile-colors-white-base, var(--ng-colors-bg-primary));
|
43
|
-
outline:
|
43
|
+
outline: solid var(--nile-outline-0-5px, var(--ng-outline-1px)) var(--border-color);
|
44
44
|
outline-offset: var(--nile-outline-none, --ng-outline-neg-1);
|
45
45
|
border-radius: var(--border-radius);
|
46
46
|
min-width: 273px;
|
package/src/nile-icon/index.ts
CHANGED
@@ -68,9 +68,6 @@ export class NileIcon extends LitElement {
|
|
68
68
|
@property({ type: String, reflect: true })
|
69
69
|
public size = SMALL_ICON_SIZE;
|
70
70
|
|
71
|
-
@property({ type: String, reflect: true })
|
72
|
-
public size_token = '';
|
73
|
-
|
74
71
|
@state()
|
75
72
|
private _svg = '';
|
76
73
|
|
@@ -117,7 +114,7 @@ export class NileIcon extends LitElement {
|
|
117
114
|
stroke: var(--nile-svg-stroke);
|
118
115
|
}
|
119
116
|
|
120
|
-
.nds-icon svg
|
117
|
+
.nds-icon svg * {
|
121
118
|
fill: var(--nile-svg-fill);
|
122
119
|
}
|
123
120
|
|
@@ -148,11 +145,6 @@ export class NileIcon extends LitElement {
|
|
148
145
|
this.style.setProperty('--nile-svg-height', `${this.size}px`);
|
149
146
|
this.style.setProperty('--nile-svg-width', `${this.size}px`);
|
150
147
|
}
|
151
|
-
|
152
|
-
if (changedProperties.has('size_token')) {
|
153
|
-
this.style.setProperty('--nile-svg-height', `${this.size_token}`);
|
154
|
-
this.style.setProperty('--nile-svg-width', `${this.size_token}`);
|
155
|
-
}
|
156
148
|
|
157
149
|
if (changedProperties.has('color')) {
|
158
150
|
this.style.setProperty('--nile-svg-fill', `${this.color}`);
|
@@ -122,6 +122,16 @@ export class NileIconButton extends NileElement {
|
|
122
122
|
this.ishovered = false;
|
123
123
|
}
|
124
124
|
|
125
|
+
private getTokenValueResolved(): any {
|
126
|
+
const thisValue = this;
|
127
|
+
|
128
|
+
const value = Number(getComputedStyle(thisValue).getPropertyValue('--nile-width-14px').trim().split('px')[0]);
|
129
|
+
if (!value) {
|
130
|
+
return Number(getComputedStyle(thisValue).getPropertyValue('--ng-height-12px').trim().split('px')[0]);
|
131
|
+
}
|
132
|
+
return value;
|
133
|
+
}
|
134
|
+
|
125
135
|
render(): TemplateResult {
|
126
136
|
const isLink = this.href ? true : false;
|
127
137
|
const tag = isLink ? literal`a` : literal`button`;
|
@@ -161,7 +171,7 @@ export class NileIconButton extends NileElement {
|
|
161
171
|
src=${ifDefined(this.src)}
|
162
172
|
.color=${this.color}
|
163
173
|
aria-hidden="true"
|
164
|
-
|
174
|
+
size="${this.getTokenValueResolved()}"
|
165
175
|
></nile-icon>
|
166
176
|
</a>
|
167
177
|
`;
|
@@ -201,7 +211,7 @@ export class NileIconButton extends NileElement {
|
|
201
211
|
src=${ifDefined(this.src)}
|
202
212
|
.color=${this.color}
|
203
213
|
aria-hidden="true"
|
204
|
-
|
214
|
+
size="${this.getTokenValueResolved()}"
|
205
215
|
></nile-icon>
|
206
216
|
</button>
|
207
217
|
`;
|
@@ -1960,7 +1960,7 @@
|
|
1960
1960
|
},
|
1961
1961
|
{
|
1962
1962
|
"name": "nile-icon",
|
1963
|
-
"description": "Nile icon component.\n\nAttributes:\n\n * `set` {IconName | undefined} - The name of the icon set\n\n * `name` {IconName | undefined} - The name of the icon\n\n * `description` {`string`} - A description of what the icon represents\n\n * `method` {`string`} - \n\n * `customSvgPath` {`string | undefined`} - A path to a custom SVG file to display as the icon\n\n * `size` {`number`} - A size of what the icon represents\n\n * `
|
1963
|
+
"description": "Nile icon component.\n\nAttributes:\n\n * `set` {IconName | undefined} - The name of the icon set\n\n * `name` {IconName | undefined} - The name of the icon\n\n * `description` {`string`} - A description of what the icon represents\n\n * `method` {`string`} - \n\n * `customSvgPath` {`string | undefined`} - A path to a custom SVG file to display as the icon\n\n * `size` {`number`} - A size of what the icon represents\n\n * `color` - Color\n\n * `push` {`boolean`} - \n\n * `noFill` {`boolean`} - \n\n * `frame` - Retain Viewbox\n\n * `override` - \n\nProperties:\n\n * `set` {IconName | undefined} - The name of the icon set\n\n * `name` {IconName | undefined} - The name of the icon\n\n * `description` {`string`} - A description of what the icon represents\n\n * `method` {`string`} - \n\n * `customSvgPath` {`string | undefined`} - A path to a custom SVG file to display as the icon\n\n * `size` {`number`} - A size of what the icon represents\n\n * `_svg` {`string`} - \n\n * `title` {`string`} - \n\n * `color` - Color\n\n * `push` {`boolean`} - \n\n * `noFill` {`boolean`} - \n\n * `frame` - Retain Viewbox\n\n * `styles` - \n\n * `buttonClassMap` {`ButtonClassMap`} - \n\n * `override` - ",
|
1964
1964
|
"attributes": [
|
1965
1965
|
{
|
1966
1966
|
"name": "set",
|
@@ -1989,10 +1989,6 @@
|
|
1989
1989
|
"name": "size",
|
1990
1990
|
"description": "`size` {`number`} - A size of what the icon represents\n\nProperty: size\n\nDefault: 16"
|
1991
1991
|
},
|
1992
|
-
{
|
1993
|
-
"name": "size_token",
|
1994
|
-
"description": "`size_token` {`string`} - \n\nProperty: size_token\n\nDefault: "
|
1995
|
-
},
|
1996
1992
|
{
|
1997
1993
|
"name": "color",
|
1998
1994
|
"description": "`color` - Color\n\nProperty: color"
|