diff --git a/resources/js/components/SMButton.vue b/resources/js/components/SMButton.vue
index d7030ff..b0a46fd 100644
--- a/resources/js/components/SMButton.vue
+++ b/resources/js/components/SMButton.vue
@@ -7,17 +7,12 @@
classType,
props.size,
{ 'button-block': block },
- { 'dropdown-button': dropdown },
+ { 'button-dropdown': dropdown },
]"
ref="buttonRef"
:style="{ minWidth: minWidth }"
:type="buttonType"
@click="handleClick">
-
- {{ props.label }}
+
+
+
+ {{ label }}
+
+
+
+
+
+
+ {{ label }}
+
+
+
- {{ label }}
+
+
+ {{ label }}
+
+
-
- {{ label }}
-
+
+
+ {{ label }}
+
+
@@ -66,10 +86,10 @@ const props = defineProps({
},
iconLocation: {
type: String,
- default: "after",
+ default: "",
required: false,
validator: (value: string) => {
- return ["before", "after"].includes(value);
+ return ["before", "after", ""].includes(value);
},
},
to: {
@@ -168,6 +188,53 @@ const handleClickItem = (item: string) => {
background-color: var(--base-color-light);
text-decoration: none;
box-shadow: 0 0 4px rgba(0, 0, 0, 0.2);
+ -webkit-user-select: none;
+ -moz-user-select: none;
+ -ms-user-select: none;
+ user-select: none;
+
+ .button-label {
+ ion-icon {
+ width: 28px;
+ height: 28px;
+ margin: -8px 0;
+ }
+ }
+
+ &.button-dropdown {
+ position: relative;
+
+ .button-icon-dropdown {
+ height: 18px;
+ width: 18px;
+ margin: -2px -18px -2px 8px;
+ }
+
+ &.medium .button-icon-dropdown {
+ height: 16px;
+ width: 16px;
+ margin: -4px -18px -3px 8px;
+ }
+
+ ul {
+ position: absolute;
+ list-style-type: none;
+ display: none;
+ z-index: 10;
+ top: 50%;
+ right: 0;
+ margin: 0;
+ padding: 0;
+ background-color: inherit;
+ border-color: #999;
+ box-shadow: 0 0 4px rgba(0, 0, 0, 0.2);
+
+ li {
+ margin: 0;
+ padding: 24px;
+ }
+ }
+ }
&:hover:not(:disabled) {
box-shadow: 0 0 4px rgba(0, 0, 0, 0.5);