Skip to content

Commit

Permalink
Fix: Contact Buttons v4 - buttons and icon sizes, control label (#27466)
Browse files Browse the repository at this point in the history
## PR Checklist
<!-- 
Please check if your PR fulfills the following requirements:
**Filling out the template is required.** Any pull request that does not
include enough information to be reviewed in a timely manner may be
closed at the maintainers' discretion.
 -->
- [ ] The commit message follows our guidelines:
https://github.com/elementor/elementor/blob/master/.github/CONTRIBUTING.md


## PR Type
What kind of change does this PR introduce?
<!-- Please check the one that applies to this PR using "x" with no
spaces eg: [x]. -->
- [ ] Bugfix
- [ ] Feature
- [ ] Code style update (formatting, local variables)
- [ ] Refactoring (no functional changes, no api changes)
- [ ] Build related changes
- [ ] CI related changes
- [ ] Documentation content changes
- [ ] Other... Please describe:

## Summary

This PR can be summarized in the following changelog entry:

*

## Description
An explanation of what is done in this PR

*

## Test instructions
This PR can be tested by following these steps:

*

## Quality assurance

- [ ] I have tested this code to the best of my abilities
- [ ] I have added unittests to verify the code works as intended
- [ ] Docs have been added / updated (for bug fixes / features)

Fixes #
  • Loading branch information
mserino committed May 23, 2024
1 parent ac6244c commit c0b1876
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 46 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,35 +2,52 @@
--e-contact-buttons-size-small: 45px;
--e-contact-buttons-size-medium: 50px;
--e-contact-buttons-size-large: 55px;
--e-contact-buttons-icon-small: 20px;
--e-contact-buttons-icon-medium: 24px;
--e-contact-buttons-icon-large: 26px;
--e-contact-buttons-button-bg-hover: #324A6D;
--e-contact-buttons-close-button-color: #1C2448;
--e-contact-buttons-contact-button-icon-hover: #467FF7;
--e-contact-buttons-contact-button-bg-hover: #FFFFFF;

.e-contact-buttons__chat-button,
.e-contact-buttons__contact-icon-link {

&.has-size-small {

.has-size-small {
&.e-contact-buttons__chat-button,
&.e-contact-buttons__close-button,
& .e-contact-buttons__contact-icon-container {
height: var(--e-contact-buttons-size-small);
width: var(--e-contact-buttons-size-small);

svg {
height: 26px;
width: 26px;
height: var(--e-contact-buttons-icon-small);
width: var(--e-contact-buttons-icon-small);
}
}
}

&.has-size-medium {

.has-size-medium {
&.e-contact-buttons__chat-button,
&.e-contact-buttons__close-button,
& .e-contact-buttons__contact-icon-container {
height: var(--e-contact-buttons-size-medium);
width: var(--e-contact-buttons-size-medium);

svg {
height: 30px;
width: 30px;
height: var(--e-contact-buttons-icon-medium);
width: var(--e-contact-buttons-icon-medium);
}
}
}

&.has-size-large {

.has-size-large {
&.e-contact-buttons__chat-button,
&.e-contact-buttons__close-button,
& .e-contact-buttons__contact-icon-container {
height: var(--e-contact-buttons-size-large);
width: var(--e-contact-buttons-size-large);

svg {
height: 32px;
width: 32px;
height: var(--e-contact-buttons-icon-large);
width: var(--e-contact-buttons-icon-large);
}
}
}
Expand All @@ -46,21 +63,6 @@
inset-inline-start: unset;
position: relative;
top: unset;

&.has-size-small {
height: var(--e-contact-buttons-size-small);
width: var(--e-contact-buttons-size-small);
}

&.has-size-medium {
height: var(--e-contact-buttons-size-medium);
width: var(--e-contact-buttons-size-medium);
}

&.has-size-large {
height: var(--e-contact-buttons-size-large);
width: var(--e-contact-buttons-size-large);
}
}

.e-contact-buttons__close-button,
Expand Down Expand Up @@ -117,21 +119,6 @@
fill: var(--e-contact-buttons-contact-button-icon-hover);
}
}

&.has-size-small .e-contact-buttons__contact-icon-container {
height: var(--e-contact-buttons-icon-size-small);
width: var(--e-contact-buttons-icon-size-small);
}

&.has-size-medium .e-contact-buttons__contact-icon-container {
height: var(--e-contact-buttons-icon-size-medium);
width: var(--e-contact-buttons-icon-size-medium);
}

&.has-size-large .e-contact-buttons__contact-icon-container {
height: var(--e-contact-buttons-icon-size-large);
width: var(--e-contact-buttons-icon-size-large);
}
}

.e-contact-buttons__contact-tooltip {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -513,7 +513,7 @@ protected function add_contact_section(): void {
$repeater->add_control(
'contact_icon_mail',
[
'label' => esc_html__( 'Mail', 'elementor' ),
'label' => esc_html__( 'Email', 'elementor' ),
'type' => Controls_Manager::TEXT,
'placeholder' => esc_html__( 'Enter your email', 'elementor' ),
'dynamic' => [
Expand Down

0 comments on commit c0b1876

Please sign in to comment.