Skip to content

Commit

Permalink
Update users of AuIcon to explicitly accept inline icon components
Browse files Browse the repository at this point in the history
  • Loading branch information
piemonkey committed Mar 20, 2024
1 parent 287d5a9 commit 56069b1
Show file tree
Hide file tree
Showing 7 changed files with 15 additions and 15 deletions.
4 changes: 2 additions & 2 deletions addon/components/au-alert.gts
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@ import { on } from '@ember/modifier';
import { action } from '@ember/object';
import Component from '@glimmer/component';
import { tracked } from '@glimmer/tracking';
import AuIcon from './au-icon';
import AuIcon, { type AuIconSignature } from './au-icon';

export interface AuAlertSignature {
Args: {
closable?: boolean;
icon?: string;
icon?: AuIconSignature['Args']['icon'];
iconVisible?: boolean;
onClose?: () => void;
size?: 'tiny' | 'small';
Expand Down
4 changes: 2 additions & 2 deletions addon/components/au-badge.gts
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import Component from '@glimmer/component';
import AuIcon from './au-icon';
import AuIcon, { type AuIconSignature } from './au-icon';

export interface AuBadgeSignature {
Args: {
icon?: string;
icon?: AuIconSignature['Args']['icon'];
iconVisible?: boolean;
number?: number;
size?: 'small';
Expand Down
4 changes: 2 additions & 2 deletions addon/components/au-button.gts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import Component from '@glimmer/component';
import AuIcon from './au-icon';
import AuIcon, { type AuIconSignature } from './au-icon';
import { LoadingAnimation } from '../private/components/loading-animation';

const SKINS = [
Expand All @@ -15,7 +15,7 @@ export interface AuButtonSignature {
alert?: boolean;
disabled?: boolean;
hideText?: boolean;
icon?: string;
icon?: AuIconSignature['Args']['icon'];
iconAlignment?: 'left' | 'right';
loading?: boolean;
loadingMessage?: string;
Expand Down
4 changes: 2 additions & 2 deletions addon/components/au-card.gts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { tracked } from '@glimmer/tracking';
import AuBadge from './au-badge';
import AuButton from './au-button';
import AuContent, { type AuContentSignature } from './au-content';
import AuIcon from './au-icon';
import AuIcon, { type AuIconSignature } from './au-icon';

export interface AuCardSignature {
Args: {
Expand Down Expand Up @@ -188,7 +188,7 @@ export default class AuCard extends Component<AuCardSignature> {

interface HeaderSignature {
Args: {
badgeIcon?: string;
badgeIcon?: AuIconSignature['Args']['icon'];
badgeNumber?: number;
badgeSize?: 'small';
badgeSkin?: 'border' | 'action' | 'brand' | 'success' | 'warning' | 'error';
Expand Down
4 changes: 2 additions & 2 deletions addon/components/au-input.gts
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import Component from '@glimmer/component';
import AuIcon from './au-icon';
import AuIcon, { type AuIconSignature } from './au-icon';

export interface AuInputSignature {
Args: {
disabled?: boolean;
error?: boolean;
icon?: string;
icon?: AuIconSignature['Args']['icon'];
iconAlignment?: 'left' | 'right';
warning?: boolean;
width?: 'block';
Expand Down
4 changes: 2 additions & 2 deletions addon/components/au-link.gts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { LinkTo } from '@ember/routing';
import Component from '@glimmer/component';
import AuIcon from './au-icon';
import AuIcon, { type AuIconSignature } from './au-icon';
import linkToModels from '../private/helpers/link-to-models';

const SKIN_CLASSES = {
Expand All @@ -22,7 +22,7 @@ export interface AuLinkSignature {
| 'button-naked';
width?: 'block';
query?: Record<string, unknown>;
icon?: string;
icon?: AuIconSignature['Args']['icon'];
route: string;
hideText?: boolean;
model?: unknown;
Expand Down
6 changes: 3 additions & 3 deletions addon/components/au-pill.gts
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
import { on } from '@ember/modifier';
import { LinkTo } from '@ember/routing';
import Component from '@glimmer/component';
import AuIcon from './au-icon';
import AuIcon, { type AuIconSignature } from './au-icon';
import linkToModels from '../private/helpers/link-to-models';

const PILL_SIZES = ['small'];

export interface AuPillSignature {
Args: {
actionIcon?: string;
actionIcon?: AuIconSignature['Args']['icon'];
actionText?: string;
draft?: boolean;
href?: string;
Expand Down Expand Up @@ -144,7 +144,7 @@ export default class AuPill extends Component<AuPillSignature> {

interface InnerSignature {
Args: {
icon?: string;
icon?: AuIconSignature['Args']['icon'];
iconAlignment?: 'left' | 'right';
hideText?: boolean;
};
Expand Down

0 comments on commit 56069b1

Please sign in to comment.