Forráskód Böngészése

feat: export utility functions (#315)

* feat: exported normalizeColor

* chore: added normalizeVectorFlexibleParam to the module exports

---------

Co-authored-by: Tino Koch <tinoooo@users.noreply.github.com>
Tino Koch 1 éve
szülő
commit
7580c77482

+ 1 - 1
playground/.eslintrc-auto-import.json

@@ -60,4 +60,4 @@
     "watchSyncEffect": true,
     "watchSyncEffect": true,
     "toValue": true
     "toValue": true
   }
   }
-}
+}

+ 3 - 1
playground/components.d.ts

@@ -3,9 +3,11 @@
 // @ts-nocheck
 // @ts-nocheck
 // Generated by unplugin-vue-components
 // Generated by unplugin-vue-components
 // Read more: https://github.com/vuejs/core/pull/3399
 // Read more: https://github.com/vuejs/core/pull/3399
+import '@vue/runtime-core'
+
 export {}
 export {}
 
 
-declare module 'vue' {
+declare module '@vue/runtime-core' {
   export interface GlobalComponents {
   export interface GlobalComponents {
     AnimatedModel: typeof import('./src/components/AnimatedModel.vue')['default']
     AnimatedModel: typeof import('./src/components/AnimatedModel.vue')['default']
     Cameras: typeof import('./src/components/Cameras.vue')['default']
     Cameras: typeof import('./src/components/Cameras.vue')['default']

+ 4 - 0
src/index.ts

@@ -5,6 +5,8 @@ export * from './core/catalogue'
 export * from './components'
 export * from './components'
 export * from './types'
 export * from './types'
 
 
+import { normalizeColor, normalizeVectorFlexibleParam } from './utils/normalize'
+
 export interface TresOptions {
 export interface TresOptions {
   extends?: Record<string, unknown>
   extends?: Record<string, unknown>
 }
 }
@@ -21,3 +23,5 @@ const plugin: TresPlugin = {
 }
 }
 
 
 export default plugin
 export default plugin
+
+export { normalizeColor, normalizeVectorFlexibleParam }