@ai-matrx/associations 0.13.20 → 0.13.22

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.
@@ -4469,7 +4469,8 @@ var import_jsx_runtime14 = require("react/jsx-runtime");
4469
4469
  function AssociationCaptureToolbar({
4470
4470
  attach,
4471
4471
  uploadFolderPath,
4472
- uploadVisibility = "personal",
4472
+ uploadPublishedToWeb = false,
4473
+ uploadShownTo = "only_me",
4473
4474
  uploadLocationLabel,
4474
4475
  attachRetryLabel = '"Add file"',
4475
4476
  filePicker,
@@ -4498,10 +4499,8 @@ function AssociationCaptureToolbar({
4498
4499
  const failed = [];
4499
4500
  for (const file of opts.files) {
4500
4501
  try {
4501
- const result = await hostUploadFile(file, {
4502
- folderPath: opts.folderPath,
4503
- ...opts.visibility !== void 0 ? { visibility: opts.visibility } : {}
4504
- });
4502
+ const { files: _files, ...uploadOpts } = opts;
4503
+ const result = await hostUploadFile(file, uploadOpts);
4505
4504
  if (result.ok) uploaded.push(result.id);
4506
4505
  else failed.push({ name: file.name, error: result.error });
4507
4506
  } catch (err) {
@@ -4537,7 +4536,10 @@ function AssociationCaptureToolbar({
4537
4536
  const result = await requestUpload({
4538
4537
  files,
4539
4538
  folderPath: uploadFolderPath,
4540
- visibility: uploadVisibility
4539
+ publishedToWeb: uploadPublishedToWeb,
4540
+ shownTo: uploadShownTo,
4541
+ visibility: uploadPublishedToWeb ? "public" : uploadShownTo === "only_me" ? "personal" : "internal"
4542
+ // T-13 transitional wire input
4541
4543
  });
4542
4544
  if (result.cancelled) {
4543
4545
  notifier.success("Upload cancelled \u2014 nothing was attached");