Skip to content

Commit 676099c

Browse files
committed
Remove sizing option
1 parent a4293be commit 676099c

File tree

3 files changed

+3
-36
lines changed

3 files changed

+3
-36
lines changed

packages/uui-base/lib/types/Size.ts

Lines changed: 0 additions & 3 deletions
This file was deleted.

packages/uui-base/lib/types/index.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1 @@
11
export * from './InterfaceLook';
2-
export * from './Size';

packages/uui-tag/lib/uui-tag.element.ts

Lines changed: 3 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,12 @@ import { property } from 'lit/decorators.js';
33
import {
44
InterfaceLookType,
55
InterfaceLookDefaultValue,
6-
Size,
76
} from '@umbraco-ui/uui-base/lib/types';
87

98
/**
109
* Tag component from Umbraco UI components library. Comes in one shape, but different looks and sizes
1110
* @element uui-tag
1211
* @slot - for tag contents
13-
* @cssprop --uui-tag-font-size - Set the components font size. Setting this property overwrites what comes from size attribute.
1412
*/
1513
export class UUITagElement extends LitElement {
1614
static styles = [
@@ -19,9 +17,9 @@ export class UUITagElement extends LitElement {
1917
display: inline-block;
2018
font-family: inherit;
2119
font-weight: 700;
22-
line-height: 1.1;
23-
font-size: var(--uui-tag-font-size, 0.9em);
24-
padding: calc(var(--uui-tag-font-size) / 2.3) var(--uui-tag-font-size);
20+
line-height: 1.1; /* should have have another line height, lets check with multiple line tag. */
21+
/*font-size: var(--uui-tag-font-size, 0.9em);*/
22+
padding: 0.5em 1em;
2523
border-radius: 1000px;
2624
background-color: var(--uui-interface-surface-alt);
2725
color: var(--uui-interface-contrast);
@@ -34,24 +32,6 @@ export class UUITagElement extends LitElement {
3432
align-items: center;
3533
}
3634
37-
/** TODO: Revisit size options: */
38-
39-
:host([size='xs']) {
40-
--uui-tag-font-size: 10px;
41-
}
42-
:host([size='s']) {
43-
--uui-tag-font-size: 11px;
44-
}
45-
:host([size='m']) {
46-
--uui-tag-font-size: 12px;
47-
}
48-
:host([size='l']) {
49-
--uui-tag-font-size: 13px;
50-
}
51-
:host([size='xl']) {
52-
--uui-tag-font-size: 14px;
53-
}
54-
5535
/* Looks */
5636
:host([look='primary']) {
5737
background-color: var(--uui-look-primary-surface);
@@ -92,15 +72,6 @@ export class UUITagElement extends LitElement {
9272
`,
9373
];
9474

95-
/**
96-
* Defines the size of the tag. It changes the `--uui-tag-font-size` value.
97-
* @type {'xs' | 's' | 'm' | 'l' | 'xl'}
98-
* @attr
99-
* @default m
100-
*/
101-
@property({ reflect: true })
102-
public size: Size = 'm';
103-
10475
/**
10576
* Defines the look of the tag.
10677
* @type {''|'primary'|'secondary'|'outline'|'placeholder'|'positive'|'warning'|'danger'}

0 commit comments

Comments
 (0)