diff --git a/import-meta.d.ts b/import-meta.ts
similarity index 58%
rename from import-meta.d.ts
rename to import-meta.ts
index 3a28cb1..e7708dd 100644
--- a/import-meta.d.ts
+++ b/import-meta.ts
@@ -1,4 +1,4 @@
-interface ImportMeta {
+export interface ImportMetaExtras extends ImportMeta {
env: {
APP_URL: string;
[key: string]: string;
diff --git a/resources/js/components/SMButton.vue b/resources/js/components/SMButton.vue
index fa89825..f59fe9d 100644
--- a/resources/js/components/SMButton.vue
+++ b/resources/js/components/SMButton.vue
@@ -5,6 +5,7 @@
:class="[
'sm-button',
classType,
+ { 'sm-button-small': small },
{ 'sm-button-block': block },
{ 'sm-dropdown-button': dropdown },
]"
@@ -37,7 +38,12 @@
v-else-if="!isEmpty(to) && typeof to == 'string'"
:href="to"
:disabled="disabled"
- :class="['sm-button', classType, { 'sm-button-block': block }]"
+ :class="[
+ 'sm-button',
+ classType,
+ { 'sm-button-small': small },
+ { 'sm-button-block': block },
+ ]"
:type="buttonType">
{{ label }}
@@ -46,7 +52,12 @@
v-else-if="!isEmpty(to) && typeof to == 'object'"
:to="to"
:disabled="disabled"
- :class="['sm-button', classType, { 'sm-button-block': block }]">
+ :class="[
+ 'sm-button',
+ classType,
+ { 'sm-button-small': small },
+ { 'sm-button-block': block },
+ ]">
{{ label }}
@@ -67,7 +78,7 @@ const props = defineProps({
},
iconLocation: {
type: String,
- default: "before",
+ default: "after",
required: false,
validator: (value: string) => {
return ["before", "after"].includes(value);
@@ -89,6 +100,11 @@ const props = defineProps({
default: false,
required: false,
},
+ small: {
+ type: Boolean,
+ default: false,
+ required: false,
+ },
dropdown: {
type: Object,
default: null,
diff --git a/resources/js/components/SMForm.vue b/resources/js/components/SMForm.vue
index 6ba071b..88c9bbc 100644
--- a/resources/js/components/SMForm.vue
+++ b/resources/js/components/SMForm.vue
@@ -27,8 +27,8 @@ const emits = defineEmits(["submit"]);
/**
* Handle the user submitting the form.
*/
-const handleSubmit = function () {
- if (props.modelValue.validate()) {
+const handleSubmit = async function () {
+ if (await props.modelValue.validate()) {
emits("submit");
}
};
diff --git a/resources/js/components/SMHTML.vue b/resources/js/components/SMHTML.vue
index 601b3b2..001b94c 100644
--- a/resources/js/components/SMHTML.vue
+++ b/resources/js/components/SMHTML.vue
@@ -5,7 +5,7 @@
+
+
diff --git a/resources/js/components/SMPanel.vue b/resources/js/components/SMPanel.vue
index 86e25fd..faaafe0 100644
--- a/resources/js/components/SMPanel.vue
+++ b/resources/js/components/SMPanel.vue
@@ -31,7 +31,11 @@
{{ computedContent }}
-
+
@@ -288,5 +292,9 @@ watch(
line-height: 130%;
flex: 1;
}
+
+ .sm-panel-button {
+ margin-top: map-get($spacer, 4);
+ }
}
diff --git a/resources/js/components/SMToolbar.vue b/resources/js/components/SMToolbar.vue
index ed6b93d..1171288 100644
--- a/resources/js/components/SMToolbar.vue
+++ b/resources/js/components/SMToolbar.vue
@@ -1,14 +1,25 @@