Skip to content

Commit 59ba289

Browse files
authored
refactor(spinner): use mode to render default (#29768)
1 parent 32fb17c commit 59ba289

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

core/src/components/spinner/spinner.tsx

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import { Component, Host, Prop, h } from '@stencil/core';
33
import { createColorClasses } from '@utils/theme';
44

55
import { config } from '../../global/config';
6-
import { getIonTheme } from '../../global/ionic-global';
6+
import { getIonTheme, getIonMode } from '../../global/ionic-global';
77
import type { Color } from '../../interface';
88

99
import type { SpinnerTypes } from './spinner-configs';
@@ -58,14 +58,13 @@ export class Spinner implements ComponentInterface {
5858
*/
5959
@Prop() size?: 'xsmall' | 'small' | 'medium' | 'large' | 'xlarge';
6060

61-
// TODO(ROU-10920): Switch `theme` to `mode`.
6261
private getName(): SpinnerTypes {
6362
const spinnerName = this.name || config.get('spinner');
64-
const theme = getIonTheme(this);
63+
const mode = getIonMode(this);
6564
if (spinnerName) {
6665
return spinnerName;
6766
}
68-
return theme === 'ios' ? 'lines' : 'circular';
67+
return mode === 'ios' ? 'lines' : 'circular';
6968
}
7069

7170
private getSize(): string | undefined {

0 commit comments

Comments
 (0)