@@ -86,15 +86,15 @@ function buildBackground(
8686 * Calculates the position of all elements within a card based on direction (RTL/LTR),
8787 * animation status, and revert mode.
8888 *
89- * @param {boolean|undefined } isRtl - Whether to use right-to-left direction.
90- * @param {boolean|undefined } isAnimDisabled - Whether animation is disabled.
91- * @param {boolean|undefined } isRevert - Whether the layout is reversed (revert).
89+ * @param {boolean } isRtl - Whether to use right-to-left direction.
90+ * @param {boolean } isAnimDisabled - Whether animation is disabled.
91+ * @param {boolean } isRevert - Whether the layout is reversed (revert).
9292 * @returns {Object } An object containing the X/Y coordinates for each element.
9393 */
9494function getPositions (
95- isRtl : boolean | undefined ,
96- isAnimDisabled : boolean | undefined ,
97- isRevert : boolean | undefined
95+ isRtl : boolean ,
96+ isAnimDisabled : boolean ,
97+ isRevert : boolean
9898) {
9999 const titleX = isAnimDisabled ? ( isRtl ? 520 : 15 ) : ( isRtl ? 510 : 5 ) ;
100100 const titleY = isAnimDisabled ? 0 : - 10 ;
@@ -163,7 +163,7 @@ function getAnimationStyles(
163163export default async function card ( data : GetData , uiConfig : UiConfig ) : Promise < string > {
164164 const fallbackLocale = "en" ;
165165 const defaultLocale = locales [ fallbackLocale ] ;
166- const selectedLocale = locales [ uiConfig . Locale ] || defaultLocale ;
166+ const selectedLocale = locales [ uiConfig . Locale ] ;
167167
168168 const isRtl = parseBoolean ( selectedLocale . rtlDirection || false ) ;
169169 const isAnimDisabled = parseBoolean ( uiConfig . disabledAnimations || uiConfig . Format === "png" ) ;
0 commit comments