Skip to content

Commit

Permalink
feat: button background hover styles while loading
Browse files Browse the repository at this point in the history
  • Loading branch information
tikagan committed Sep 14, 2023
1 parent e771e13 commit 7fee6b9
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions components/button/cta-with-loader.vue
Original file line number Diff line number Diff line change
Expand Up @@ -62,10 +62,10 @@ const props = defineProps({

<style lang="scss" scoped>
// ///////////////////////////////////////////////////////////////////// General
.with-loader.theme__primary.loading {
.with-loader.theme__primary {
&:hover {
cursor: default;
:deep(.detail) {
:deep(.inner-content.loading) {
.fill-path {
opacity: 0;
fill: none;
Expand Down
5 changes: 2 additions & 3 deletions components/button/cta.vue
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,8 @@
<ZeroButton
v-slot="{ loading }"
v-bind="props"
:class="['button-x', `theme__${props.theme}`, variant, loading]">
<div class="inner-content">

:class="['button-x', `theme__${props.theme}`, variant]">
<div :class="['inner-content', { loading: loading }]">
<div v-if="theme === 'primary'" :class="['detail-wrapper', variant]">
<svg
width="400"
Expand Down
3 changes: 2 additions & 1 deletion components/signup-card.vue
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@
</div>

<ButtonCtaWithLoader
:class="['submit-button', { submitted: formSubmitted }]"
:class="['submit-button', { submitted: !loading && formSubmitted }]"
theme="primary"
loader="signup-card-form"
@clicked="submitForm">
Expand Down Expand Up @@ -199,6 +199,7 @@ const selectOption = (setSelected, closePanel, option, field) => {
* @method submitForm
*/
const submitForm = async () => {
if (formSubmitted.value) { return }
if (firstName.value && lastName.value && email.value && organization.value && country.value) {
const body = {
records: [
Expand Down

0 comments on commit 7fee6b9

Please sign in to comment.