mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-16 19:01:05 +00:00
feat(link): support "sm", "lg" size variants
This commit is contained in:
parent
5a5587c115
commit
6dd363c2a9
5 changed files with 54 additions and 24 deletions
|
@ -1,4 +1,10 @@
|
|||
<script>
|
||||
/**
|
||||
* Specify the size of the link
|
||||
* @type {"sm" | "lg"} [size]
|
||||
*/
|
||||
export let size = undefined;
|
||||
|
||||
/**
|
||||
* Specify the href value
|
||||
* @type {string} [href]
|
||||
|
@ -53,6 +59,8 @@
|
|||
class:bx--link--disabled="{disabled}"
|
||||
class:bx--link--inline="{inline}"
|
||||
class:bx--link--visited="{visited}"
|
||||
class:bx--link--sm="{size === 'sm'}"
|
||||
class:bx--link--lg="{size === 'lg'}"
|
||||
rel="{$$restProps.target === '_blank' ? 'noopener noreferrer' : undefined}"
|
||||
href="{href}"
|
||||
{...$$restProps}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue