Skip to content

Commit

Permalink
feat(cc-zone-input): make use of the cc-notice instead of cc-error
Browse files Browse the repository at this point in the history
  • Loading branch information
Galimede committed Jul 3, 2023
1 parent aceb9cc commit 73e44a1
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions src/components/cc-zone-input/cc-zone-input.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import '../cc-zone/cc-zone.js';
import '../cc-map/cc-map.js';
import '../cc-notice/cc-notice.js';
import '../cc-map-marker-server/cc-map-marker-server.js';
import { css, html, LitElement } from 'lit';
import { classMap } from 'lit/directives/class-map.js';
Expand Down Expand Up @@ -194,7 +195,7 @@ export class CcZoneInput extends withResizeObserver(LitElement) {
</cc-map>
<div class="zone-list-wrapper">
${this.error ? html`
<cc-error>${i18n('cc-zone-input.error')}</cc-error>
<cc-notice intent="warning" message="${i18n('cc-zone-input.error')}"></cc-notice>
` : ''}
${!this.error ? html`
<div class="zone-list">
Expand Down Expand Up @@ -280,13 +281,13 @@ export class CcZoneInput extends withResizeObserver(LitElement) {
max-width: 24em;
flex-basis: 24em;
}
:host([error]) .zone-list-wrapper {
display: flex;
padding: 1em;
:host([error]) {
border: none;
}
:host([error]) cc-error {
:host([error]) cc-notice {
width: 100%;
margin: auto;
}
Expand Down

0 comments on commit 73e44a1

Please sign in to comment.