budibase/packages/client/src/sdk.js

79 lines
1.7 KiB
JavaScript
Raw Normal View History

import { API } from "api"
2021-01-22 12:44:43 +01:00
import {
authStore,
notificationStore,
routeStore,
screenStore,
builderStore,
uploadStore,
rowSelectionStore,
componentStore,
currentRole,
environmentStore,
sidePanelStore,
dndIsDragging,
2022-11-24 21:06:31 +01:00
confirmationStore,
roleStore,
2023-10-30 13:46:44 +01:00
appStore,
2023-11-07 15:36:57 +01:00
stateStore,
createContextStore,
} from "stores"
import { styleable } from "utils/styleable"
import { linkable } from "utils/linkable"
import { getAction } from "utils/getAction"
import Provider from "components/context/Provider.svelte"
import Block from "components/Block.svelte"
import BlockComponent from "components/BlockComponent.svelte"
import { ActionTypes } from "./constants"
import { fetchDatasourceSchema } from "./utils/schema.js"
import { getAPIKey } from "./utils/api.js"
2023-11-01 17:45:37 +01:00
import { enrichButtonActions } from "./utils/buttonActions.js"
import { generateGoldenSample } from "./utils/components.js"
2023-11-20 09:30:42 +01:00
import { processStringSync, makePropSafe } from "@budibase/string-templates"
import { fetchData, LuceneUtils, Constants } from "@budibase/frontend-core"
export default {
API,
2023-11-01 17:45:37 +01:00
// Stores
authStore,
2023-10-30 13:46:44 +01:00
appStore,
notificationStore,
routeStore,
rowSelectionStore,
screenStore,
builderStore,
uploadStore,
componentStore,
environmentStore,
sidePanelStore,
dndIsDragging,
currentRole,
2022-11-24 21:06:31 +01:00
confirmationStore,
roleStore,
2023-11-07 15:36:57 +01:00
stateStore,
2023-11-01 17:45:37 +01:00
// Utils
styleable,
linkable,
getAction,
fetchDatasourceSchema,
2024-01-20 22:11:31 +01:00
fetchData,
LuceneUtils,
ContextScopes: Constants.ContextScopes,
getAPIKey,
2023-11-01 17:45:37 +01:00
enrichButtonActions,
2023-11-07 15:36:57 +01:00
processStringSync,
2023-11-20 09:30:42 +01:00
makePropSafe,
createContextStore,
generateGoldenSample,
2023-11-01 17:45:37 +01:00
// Components
Provider,
Block,
BlockComponent,
2023-11-01 17:45:37 +01:00
// Constants
ActionTypes,
}