Skip to content
This repository was archived by the owner on Jan 30, 2026. It is now read-only.

Commit 1afb3a5

Browse files
committed
chore: refactor release configuration and update paths for changelog and package files
1 parent 594e6bf commit 1afb3a5

3 files changed

Lines changed: 15 additions & 13 deletions

File tree

.releaserc.cjs

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,15 +23,14 @@ const config = {
2323
plugins: [
2424
'@semantic-release/commit-analyzer',
2525
'@semantic-release/release-notes-generator',
26-
// NPM plugin MUST come before git plugin - ADD pkgRoot HERE!
26+
// NPM plugin MUST come before git plugin
2727
[
2828
'@semantic-release/npm',
2929
{
3030
npmPublish: true,
31-
pkgRoot: 'packages/superdoc'
31+
pkgRoot: '.'
3232
}
3333
],
34-
'./scripts/publish-superdoc.cjs'
3534
],
3635
}
3736

@@ -45,7 +44,7 @@ if (!isPrerelease) {
4544
config.plugins.push([
4645
'@semantic-release/changelog',
4746
{
48-
changelogFile: 'packages/superdoc/CHANGELOG.md' // Also specify where changelog goes
47+
changelogFile: 'CHANGELOG.md'
4948
}
5049
])
5150

@@ -54,8 +53,8 @@ if (!isPrerelease) {
5453
'@semantic-release/git',
5554
{
5655
assets: [
57-
'packages/superdoc/CHANGELOG.md',
58-
'packages/superdoc/package.json' // Update paths to point to actual package
56+
'CHANGELOG.md',
57+
'package.json'
5958
],
6059
message:
6160
'chore(release): ${nextRelease.version} [skip ci]\n\n${nextRelease.notes}',

CHANGELOG.md

Whitespace-only changes.

src/index.tsx

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -409,7 +409,7 @@ const SuperDocESign = forwardRef<SuperDocESignHandle, SuperDocESignProps>(
409409
setConsents(new Set());
410410
startTimeRef.current = Date.now();
411411

412-
// Reset scroll
412+
// Reset scroll
413413
if (containerRef.current) {
414414
containerRef.current.scrollTop = 0;
415415
}
@@ -462,12 +462,14 @@ const SuperDocESign = forwardRef<SuperDocESignHandle, SuperDocESignProps>(
462462
return Array.from(fields.values());
463463
}, [fields]);
464464

465-
const requestDownload = useCallback(async (): Promise<DownloadRequestData | false> => {
465+
const requestDownload = useCallback(async (): Promise<
466+
DownloadRequestData | false
467+
> => {
466468
if (!superdocRef.current) return false;
467469

468470
try {
469471
const result = await superdocRef.current.export({
470-
exportType: ['docx'],
472+
exportType: ["docx"],
471473
isFinalDoc: true,
472474
triggerDownload: false,
473475
});
@@ -482,7 +484,7 @@ const SuperDocESign = forwardRef<SuperDocESignHandle, SuperDocESignProps>(
482484
await onDownloadRequest?.(downloadData);
483485
return downloadData;
484486
} catch (error) {
485-
console.error('Download request failed:', error);
487+
console.error("Download request failed:", error);
486488
return false;
487489
}
488490
}, [fields, onDownloadRequest]);
@@ -496,14 +498,15 @@ const SuperDocESign = forwardRef<SuperDocESignHandle, SuperDocESignProps>(
496498
requestDownload();
497499
};
498500

499-
const downloadElements = globalThis.document.querySelectorAll(downloadSelector);
501+
const downloadElements =
502+
globalThis.document.querySelectorAll(downloadSelector);
500503
downloadElements.forEach((el) => {
501-
el.addEventListener('click', handleDownloadClick);
504+
el.addEventListener("click", handleDownloadClick);
502505
});
503506

504507
return () => {
505508
downloadElements.forEach((el) => {
506-
el.removeEventListener('click', handleDownloadClick);
509+
el.removeEventListener("click", handleDownloadClick);
507510
});
508511
};
509512
}, [downloadSelector, isReady, requestDownload]);

0 commit comments

Comments
 (0)