Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
import { getTranslator } from './context.helper';
import { getIconPath } from './icon.helper';

const SELECTOR_INPUT = '.ids-input, .ibexa-input';
const SELECTOR_LABEL = '.ids-label';

const formatErrorLine = (errorMessage) => {
const errorIcon = `<svg class="ibexa-icon ibexa-icon--small-medium ibexa-form-error__icon">
<use xlink:href="${getIconPath('notice')}"></use>
Expand All @@ -17,8 +20,8 @@ const formatErrorLine = (errorMessage) => {
const checkIsEmpty = (field) => {
let errorMessage = '';
const Translator = getTranslator();
const input = field.querySelector('.ibexa-input');
const label = field.querySelector('.ids-label');
const input = field.querySelector(SELECTOR_INPUT);
const label = field.querySelector(SELECTOR_LABEL);

if (label) {
const fieldName = label.innerText;
Expand All @@ -34,8 +37,8 @@ const checkIsEmpty = (field) => {
};
};
const validateIsEmptyField = (field) => {
const input = field.querySelector('.ibexa-input');
const label = field.querySelector('.ids-label');
const input = field.querySelector(SELECTOR_INPUT);
const label = field.querySelector(SELECTOR_LABEL);
const errorWrapper = field.querySelector('.ibexa-form-error');
const validatorOutput = checkIsEmpty(field);
const { isValid, errorMessage } = validatorOutput;
Expand Down
26 changes: 0 additions & 26 deletions src/bundle/Resources/public/scss/_labels.scss
Original file line number Diff line number Diff line change
Expand Up @@ -5,32 +5,6 @@
.ids-label {
@include label-required();

& {
font-size: $ibexa-text-font-size-small;
color: $ibexa-color-dark-400;
line-height: calculateRem(18px);
margin-bottom: calculateRem(8px);
padding-top: 0;
padding-bottom: 0;
}

.ibexa-icon {
fill: $ibexa-color-dark-400;
}

&--checkbox-radio {
font-size: calculateRem(14px);
line-height: calculateRem(21px);
color: $ibexa-color-dark;
margin: 0 0 calculateRem(9px);

&.required {
&:after {
content: '';
}
}
}

&.form-label.is-invalid {
color: $ibexa-color-danger;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,12 @@
message: 'notification.modal.delete.confirm_message'|trans({}, 'ibexa_notifications')|desc('Are you sure you want to delete this notification?'),
} %}
{% block confirm_button %}
<button class="btn ibexa-btn ibexa-btn--primary ibexa-notifications-modal--delete--confirm" data-bs-dismiss="modal">
<twig:ibexa:button
type="primary"
class="ibexa-notifications-modal--delete--confirm"
data-bs-dismiss="modal"
>
{{ 'modal.delete'|trans|desc('Delete') }}
</button>
</twig:ibexa:button>
{% endblock %}
{% endembed %}
2 changes: 1 addition & 1 deletion src/lib/Behat/Component/Fields/Keywords.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ final class Keywords extends FieldTypeComponent
private string $setKeywordsValueScript = <<<SCRIPT
const SELECTOR_TAGGIFY = '.ibexa-data-source__taggify';
const taggifyContainer = document.querySelector(SELECTOR_TAGGIFY);
const keywordInput = taggifyContainer.closest('.ibexa-data-source').querySelector('.ibexa-data-source__input-wrapper .ibexa-data-source__input.form-control');
const keywordInput = taggifyContainer.closest('.ibexa-data-source').querySelector('.ibexa-data-source__input-wrapper .ibexa-data-source__input');
class KeywordTaggify extends window.ibexa.core.Taggify {
afterTagsUpdate() {
const tags = [...this.tags];
Expand Down
2 changes: 1 addition & 1 deletion src/lib/Behat/Page/LanguagePage.php
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ protected function specifyLocators(): array
return [
new VisibleCSSLocator('pageTitle', '.ibexa-page-title h1'),
new VisibleCSSLocator('button', '.ids-btn'),
new VisibleCSSLocator('enabledField', '.ibexa-input--checkbox'),
new VisibleCSSLocator('enabledField', '.ids-input--checkbox'),
new VisibleCSSLocator('languagePropertiesItem', '.ibexa-details__item'),
new VisibleCSSLocator('languagePropertiesLabel', '.ibexa-details__item-label'),
new VisibleCSSLocator('languagePropertiesValue', '.ibexa-details__item-content'),
Expand Down
Loading