Files
game-cards-poker-design/frontend/node_modules/fabric/src/parser/parseStyleObject.ts
Poker Design Developer 5dbcebf7a2 Fix frontend blank page issues
- Fix router import path in main.js
- Handle Django REST Framework pagination format in API calls
- Add getTemplates function to project API
- Restart frontend development server
2026-05-31 18:40:56 +08:00

18 lines
401 B
TypeScript

/**
* Takes a style object and parses it in one that has only defined values
* and lowercases properties
* @param style
* @param oStyle
*/
export function parseStyleObject(
style: Record<string, any>,
oStyle: Record<string, any>,
): void {
Object.entries(style).forEach(([prop, value]) => {
if (value === undefined) {
return;
}
oStyle[prop.toLowerCase()] = value;
});
}