@embeddable.com/sdk-core 3.13.6-next.0 → 3.13.6-next.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/lib/index.esm.js CHANGED
@@ -460,9 +460,10 @@ async function injectCSS(ctx, pluginName) {
460
460
  await fs.writeFile(path.resolve(ctx.client.componentDir, "style.css"), content.replace(STYLE_IMPORTS_TOKEN, cssFilesImportsStr));
461
461
  }
462
462
  async function injectBundleRender(ctx, pluginName) {
463
+ var _a;
463
464
  const importStr = `import render from '../${ctx[pluginName].outputOptions.buildName}/${ctx[pluginName].outputOptions.fileName}';`;
464
465
  let content = await fs.readFile(path.resolve(ctx.core.templatesDir, "component.tsx.template"), "utf8");
465
- if (!!ctx.dev) {
466
+ if (!!((_a = ctx.dev) === null || _a === undefined ? undefined : _a.watch)) {
466
467
  content = content.replace(COMPONENT_TAG_TOKEN, "embeddable-component");
467
468
  }
468
469
  await fs.writeFile(path.resolve(ctx.client.componentDir, "component.tsx"), content.replace(RENDER_IMPORT_TOKEN, importStr));
@@ -21777,6 +21778,7 @@ var push = async () => {
21777
21778
  spinnerPushing = ora("Using API key...").start();
21778
21779
  breadcrumbs.push("push by api key");
21779
21780
  await pushByApiKey(config, spinnerPushing);
21781
+ publishedSectionFeedback(config, spinnerPushing);
21780
21782
  spinnerPushing.succeed("Published using API key");
21781
21783
  return;
21782
21784
  }
@@ -21794,6 +21796,7 @@ var push = async () => {
21794
21796
  spinnerPushing.info(`Publishing to ${workspaceName} using ${workspacePreviewUrl}...`);
21795
21797
  breadcrumbs.push("send build");
21796
21798
  await sendBuild(config, { workspaceId, token, message });
21799
+ publishedSectionFeedback(config, spinnerPushing);
21797
21800
  spinnerPushing.succeed(`Published to ${workspaceName} using ${workspacePreviewUrl}`);
21798
21801
  }
21799
21802
  catch (error) {
@@ -21804,6 +21807,10 @@ var push = async () => {
21804
21807
  process.exit(1);
21805
21808
  }
21806
21809
  };
21810
+ const publishedSectionFeedback = (config, spinnerPushing) => {
21811
+ config.pushModels && spinnerPushing.succeed("Models published");
21812
+ config.pushComponents && spinnerPushing.succeed("Components published");
21813
+ };
21807
21814
  async function pushByApiKey(config, spinner) {
21808
21815
  const apiKey = getArgumentByKey(["--api-key", "-k"]);
21809
21816
  if (!apiKey) {