Skip to content

Commit

Permalink
feat(cc-article-list): 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 Jun 30, 2023
1 parent 14a4495 commit 4e8f1cd
Showing 1 changed file with 2 additions and 10 deletions.
12 changes: 2 additions & 10 deletions src/components/cc-article-list/cc-article-list.js
@@ -1,7 +1,7 @@
import { css, html, LitElement } from 'lit';
import { i18n } from '../../lib/i18n.js';
import '../cc-article-card/cc-article-card.js';
import '../cc-error/cc-error.js';
import '../cc-notice/cc-notice.js';

const ARTICLE_SKELETON_NUMBER = 9;

Expand Down Expand Up @@ -40,7 +40,7 @@ export class CcArticleList extends LitElement {
return html`
<div class="article-container">
${this.error ? html`
<cc-error>${i18n('cc-article-list.error')}</cc-error>
<cc-notice intent="warning" message="${i18n('cc-article-list.error')}"></cc-notice>
` : ''}
${skeleton && !this.error ? html`
${new Array(ARTICLE_SKELETON_NUMBER).fill(html`
Expand Down Expand Up @@ -75,14 +75,6 @@ export class CcArticleList extends LitElement {
gap: 1em;
grid-template-columns: repeat(auto-fit, minmax(20em, 1fr));
}
cc-error {
padding: 1em;
border: 1px solid var(--cc-color-border-neutral, #aaa);
background-color: var(--cc-color-bg-default, #fff);
border-radius: var(--cc-border-radius-default, 0.25em);
text-align: center;
}
`,
];
}
Expand Down

0 comments on commit 4e8f1cd

Please sign in to comment.