From 0db56065b14af4881d111dcc06937072ef565e64 Mon Sep 17 00:00:00 2001 From: majakomel Date: Thu, 11 Jul 2024 23:13:04 +0200 Subject: [PATCH] Delete unused file --- src/utils/index.ts | 18 ------------------ 1 file changed, 18 deletions(-) delete mode 100644 src/utils/index.ts diff --git a/src/utils/index.ts b/src/utils/index.ts deleted file mode 100644 index e6a26b2..0000000 --- a/src/utils/index.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { BoxKnownProps } from 'types' - -// const dsProps = [...systemProps, 'sx', 'variant'] -// const PRE = new RegExp(`^(${dsProps.join('|')})$`) - -const MRE = /^m[trblxy]?$/ - -const getProps = - (test: (a: string) => boolean) => (props: { [key: string]: any }) => { - const next: { [key: string]: any } = {} - Object.keys(props).forEach((key) => { - if (test(key || '')) next[key] = props[key] - }) - return next as BoxKnownProps - } - -export const getMarginProps = getProps((k) => MRE.test(k)) -export const omitMarginProps = getProps((k) => !MRE.test(k))