Skip to content

Commit

Permalink
add built-in check icon
Browse files Browse the repository at this point in the history
  • Loading branch information
Sveltecult committed Jan 23, 2025
1 parent 8dbf03e commit ec7c6fe
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 1 deletion.
9 changes: 9 additions & 0 deletions dist/js/uikit.js
Original file line number Diff line number Diff line change
Expand Up @@ -8995,6 +8995,8 @@
}
};

var check = "<svg width=\"16\" height=\"16\" fill=\"none\" stroke=\"currentColor\" stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" class=\"lucide lucide-check\" viewBox=\"0 0 24 24\"><path d=\"M20 6 9 17l-5-5\"/></svg>";

var closeIcon = "<svg width=\"16\" height=\"16\" fill=\"none\" stroke=\"currentColor\" stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" class=\"lucide lucide-x\" viewBox=\"0 0 24 24\"><path d=\"M18 6 6 18\"/><path d=\"m6 6 12 12\"/></svg>";

var closeLarge = "<svg width=\"16\" height=\"16\" fill=\"none\" stroke=\"currentColor\" stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" class=\"lucide lucide-x\" viewBox=\"0 0 24 24\"><path d=\"M18 6 6 18\"/><path d=\"m6 6 12 12\"/></svg>";
Expand Down Expand Up @@ -9039,6 +9041,7 @@
spinner,
totop,
marker,
check,
"close-icon": closeIcon,
"close-large": closeLarge,
"drop-parent-icon": dropParentIcon,
Expand Down Expand Up @@ -9180,6 +9183,11 @@
i18n: { label: "Previous page" },
data: { role: null }
};
const Check = {
extends: ButtonComponent,
i18n: { label: "Check" },
data: { role: null }
};
const parsed = {};
function install(UIkit) {
UIkit.icon.add = (name, svg) => {
Expand Down Expand Up @@ -9217,6 +9225,7 @@
__proto__: null,
Accordion: Accordion,
Alert: alert,
Check: Check,
Close: Close,
Cover: cover,
Drop: drop,
Expand Down
2 changes: 1 addition & 1 deletion dist/js/uikit.min.js

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions src/images/components/check.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
8 changes: 8 additions & 0 deletions src/js/core/icon.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import {
isTag,
swap,
} from 'uikit-util';
import check from '../../images/components/check.svg';
import closeIcon from '../../images/components/close-icon.svg';
import closeLarge from '../../images/components/close-large.svg';
import dropParentIcon from '../../images/components/drop-parent-icon.svg';
Expand Down Expand Up @@ -40,6 +41,7 @@ const icons = {
spinner,
totop,
marker,
check: check,
'close-icon': closeIcon,
'close-large': closeLarge,
'drop-parent-icon': dropParentIcon,
Expand Down Expand Up @@ -232,6 +234,12 @@ export const PaginationPrevious = {
data: { role: null },
};

export const Check = {
extends: ButtonComponent,
i18n: { label: 'Check' },
data: { role: null },
};

const parsed = {};
function install(UIkit) {
UIkit.icon.add = (name, svg) => {
Expand Down
1 change: 1 addition & 0 deletions src/js/core/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ export { default as Video } from './video';

// Icon components
export {
Check,
Close,
IconComponent as DropParentIcon,
Marker,
Expand Down

0 comments on commit ec7c6fe

Please sign in to comment.