Skip to content

Commit

Permalink
svg: Add missing Svg property "preserveAspectRatio" (#30618)
Browse files Browse the repository at this point in the history
  • Loading branch information
mo authored and PranavSenthilnathan committed Nov 18, 2018
1 parent a44690f commit 1d8c20d
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
4 changes: 4 additions & 0 deletions types/expo/expo-tests.tsx
Expand Up @@ -569,6 +569,10 @@ async () => {
</Svg>
);

() => (
<Svg width={100} height={50} preserveAspectRatio="none" />
);

IntentLauncherAndroid.ACTION_ACCESSIBILITY_SETTINGS === 'android.settings.ACCESSIBILITY_SETTINGS';
IntentLauncherAndroid.ACTION_APP_NOTIFICATION_REDACTION === 'android.settings.ACTION_APP_NOTIFICATION_REDACTION';
IntentLauncherAndroid.ACTION_CONDITION_PROVIDER_SETTINGS === 'android.settings.ACTION_CONDITION_PROVIDER_SETTINGS';
Expand Down
3 changes: 2 additions & 1 deletion types/expo/index.d.ts
Expand Up @@ -2139,6 +2139,7 @@ export interface SvgUseProps extends SvgCommonProps {

export interface SvgSymbolProps extends SvgCommonProps {
viewBox: string;
preserveAspectRatio?: string;
width: number | string;
height: number | string;
}
Expand Down Expand Up @@ -2166,7 +2167,7 @@ export interface SvgStopProps extends SvgCommonProps {
stopOpacity?: string;
}

export class Svg extends Component<{ width: number, height: number, viewBox?: string }> {
export class Svg extends Component<{ width: number, height: number, viewBox?: string, preserveAspectRatio?: string }> {
static Circle: ComponentClass<SvgCircleProps>;
static ClipPath: ComponentClass<SvgCommonProps>;
static Defs: ComponentClass;
Expand Down

0 comments on commit 1d8c20d

Please sign in to comment.