import { defineComponent as u, ref as r, provide as m, onMounted as S, getCurrentInstance as C, toRaw as f, onBeforeUnmount as h, openBlock as D, createElementBlock as g, watch as R } from "vue";
import { ProjectModel as v } from "@bryntum/taskboard";
import { WrapperHelper as d } from "../helper/WrapperHelper.js";
const L = /* @__PURE__ */ u({
  __name: "BryntumTaskBoardProjectModel",
  props: {
    adjustDurationToDST: {},
    assignmentModelClass: {},
    assignments: {},
    assignmentsData: {},
    assignmentStore: {},
    assignmentStoreClass: {},
    autoLoad: {},
    autoSync: {},
    autoSyncTimeout: {},
    bubbleEvents: {},
    callOnFunctions: {},
    catchEventHandlerExceptions: {},
    children: {},
    crudStores: {},
    dependencies: {},
    dependenciesData: {},
    dependencyModelClass: {},
    dependencyStore: {},
    dependencyStoreClass: {},
    encoder: {},
    events: {},
    eventsData: {},
    eventStore: {},
    expanded: {},
    forceSync: {},
    id: {},
    ignoreRemoteChangesInSTM: {},
    includeChildrenInRemoveRequest: {},
    includeLegacyDataProperties: {},
    isFullyLoaded: {},
    json: {},
    listeners: {},
    loadUrl: {},
    orderedParentIndex: {},
    parentId: {},
    parentIndex: {},
    phantomIdField: {},
    phantomParentIdField: {},
    readOnly: {},
    remoteChildCount: {},
    resetIdsBeforeSync: {},
    resourceModelClass: {},
    resources: {},
    resourcesData: {},
    resourceStore: {},
    resourceStoreClass: {},
    shouldSyncDataOnLoad: { type: Function },
    silenceInitialCommit: {},
    skipSuccessProperty: {},
    stm: {},
    storeIdProperty: {},
    supportShortSyncResponse: {},
    syncApplySequence: {},
    syncUrl: {},
    taskModelClass: {},
    tasks: {},
    tasksData: {},
    taskStore: {},
    taskStoreClass: {},
    timeZone: {},
    toJSONResultFormat: {},
    trackResponseType: {},
    transport: {},
    useRawData: {},
    validateResponse: {},
    writeAllFields: {}
  },
  emits: ["beforeDestroy", "beforeLoad", "beforeLoadApply", "beforeResponseApply", "beforeSend", "beforeSync", "beforeSyncApply", "catchAll", "change", "dataReady", "destroy", "hasChanges", "load", "loadCanceled", "loadFail", "noChanges", "requestDone", "requestFail", "sync", "syncCanceled", "syncDelayed", "syncFail"],
  setup(F, { expose: l, emit: c }) {
    const i = c, s = {
      instanceClass: v,
      instanceName: "ProjectModel",
      configNames: [
        "adjustDurationToDST",
        "assignmentModelClass",
        "assignmentsData",
        "assignmentStoreClass",
        "autoLoad",
        "autoSync",
        "autoSyncTimeout",
        "bubbleEvents",
        "children",
        "dependenciesData",
        "dependencyModelClass",
        "dependencyStoreClass",
        "encoder",
        "eventsData",
        "expanded",
        "ignoreRemoteChangesInSTM",
        "includeChildrenInRemoveRequest",
        "listeners",
        "orderedParentIndex",
        "parentIndex",
        "phantomIdField",
        "phantomParentIdField",
        "resetIdsBeforeSync",
        "resourceModelClass",
        "resourcesData",
        "resourceStoreClass",
        "silenceInitialCommit",
        "skipSuccessProperty",
        "storeIdProperty",
        "supportShortSyncResponse",
        "taskModelClass",
        "tasksData",
        "taskStoreClass",
        "toJSONResultFormat",
        "trackResponseType",
        "transport",
        "useRawData",
        "validateResponse",
        "writeAllFields"
      ],
      propertyConfigNames: [
        "assignments",
        "assignmentStore",
        "callOnFunctions",
        "catchEventHandlerExceptions",
        "crudStores",
        "dependencies",
        "dependencyStore",
        "events",
        "eventStore",
        "forceSync",
        "id",
        "includeLegacyDataProperties",
        "isFullyLoaded",
        "json",
        "loadUrl",
        "onBeforeDestroy",
        "onBeforeLoad",
        "onBeforeLoadApply",
        "onBeforeResponseApply",
        "onBeforeSend",
        "onBeforeSync",
        "onBeforeSyncApply",
        "onCatchAll",
        "onChange",
        "onDataReady",
        "onDestroy",
        "onHasChanges",
        "onLoad",
        "onLoadCanceled",
        "onLoadFail",
        "onNoChanges",
        "onRequestDone",
        "onRequestFail",
        "onSync",
        "onSyncCanceled",
        "onSyncDelayed",
        "onSyncFail",
        "parentId",
        "readOnly",
        "remoteChildCount",
        "resources",
        "resourceStore",
        "shouldSyncDataOnLoad",
        "stm",
        "syncApplySequence",
        "syncUrl",
        "tasks",
        "taskStore",
        "timeZone"
      ],
      propertyNames: [
        "descendantCount",
        "inlineData",
        "isCreating",
        "resourceTimeRanges",
        "timeRanges",
        "visibleDescendantCount"
      ],
      eventNames: [
        "beforeDestroy",
        "beforeLoad",
        "beforeLoadApply",
        "beforeResponseApply",
        "beforeSend",
        "beforeSync",
        "beforeSyncApply",
        "catchAll",
        "change",
        "dataReady",
        "destroy",
        "hasChanges",
        "load",
        "loadCanceled",
        "loadFail",
        "noChanges",
        "requestDone",
        "requestFail",
        "sync",
        "syncCanceled",
        "syncDelayed",
        "syncFail"
      ]
    }, e = {}, n = r(), t = r(/* @__PURE__ */ new Map());
    return m("teleports", t), S(() => {
      const o = C();
      e.value = d.createWidget({
        me: o,
        widgetData: s,
        emit: i,
        element: n.value,
        toRaw: f
      });
      const a = (p, y) => R(() => o.props[p], y);
      d.watchProps(e.value, s, a);
    }), h(() => {
      e.value?.destroy?.();
    }), l({
      instance: e,
      refElement: n,
      teleports: t
    }), (o, a) => (D(), g("div", {
      ref_key: "refElement",
      ref: n
    }, null, 512));
  }
});
export {
  L as _
};
//# sourceMappingURL=BU1jZXfo.js.map
