@se-studio/core-data-types 1.0.165 → 1.0.166

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/CHANGELOG.md CHANGED
@@ -1,11 +1,17 @@
1
1
  # @se-studio/core-data-types
2
2
 
3
- ## 1.0.165
3
+ ## 1.0.166
4
4
 
5
5
  ### Patch Changes
6
6
 
7
7
  - ccad4d9: Document external component type discriminator (#34): projects must use `externalComponentType` (Contentful field name), not `externalType`. Restore deferred discriminator pattern on `IBaseExternalComponent`. Consumer upgrade guide: `docs/UPGRADE_EXTERNAL_COMPONENT_TYPE.md`.
8
8
 
9
+ ## 1.0.165
10
+
11
+ ### Patch Changes
12
+
13
+ - **`IBaseArticle`** — Add optional `download?: IDownloadAsset` so full article fetches expose downloadable assets (e.g. PDFs), consistent with `IArticleLink`.
14
+
9
15
  ## 1.0.164
10
16
 
11
17
  ### Patch Changes
package/README.md CHANGED
@@ -56,6 +56,7 @@ type PartialPage = DeepPartial<IPage>;
56
56
  - `articleType?: IInternalLink` - Link to the article type
57
57
  - `contents?: ReadonlyArray<ITyped>` - Article content sections
58
58
  - `tags?: ReadonlyArray<IInternalLink>` - Tags associated with the article
59
+ - `download?: IDownloadAsset` - Optional downloadable asset (e.g. PDF)
59
60
 
60
61
  - **`IBaseArticleType`** - Base interface for article type content models
61
62
  - `type: 'Article type'` - Content type discriminator
@@ -1,4 +1,4 @@
1
- import type { IArticleTypeLink, IBaseModel, IPersonLink, ITagLink, ITyped } from './common';
1
+ import type { IArticleTypeLink, IBaseModel, IDownloadAsset, IPersonLink, ITagLink, ITyped } from './common';
2
2
  import type { ISchema } from './schema';
3
3
  import type { IVisual } from './visual';
4
4
  /**
@@ -26,6 +26,8 @@ export interface IBaseArticle extends IBaseModel {
26
26
  tags?: ReadonlyArray<ITagLink>;
27
27
  /** Additional visuals associated with the article */
28
28
  visuals?: ReadonlyArray<IVisual>;
29
+ /** Downloadable asset associated with the article (e.g. PDF) */
30
+ download?: IDownloadAsset;
29
31
  }
30
32
  /**
31
33
  * Type guard to check if content is an article.
@@ -1 +1 @@
1
- {"version":3,"file":"article.d.ts","sourceRoot":"","sources":["../../src/types/article.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,UAAU,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAC5F,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,UAAU,CAAC;AACxC,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,UAAU,CAAC;AAExC;;;;;GAKG;AACH,MAAM,WAAW,YAAa,SAAQ,UAAU;IAC9C,oDAAoD;IACpD,IAAI,EAAE,SAAS,CAAC;IAChB,0BAA0B;IAC1B,IAAI,EAAE,MAAM,CAAC;IACb,8BAA8B;IAC9B,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,sDAAsD;IACtD,WAAW,CAAC,EAAE,gBAAgB,CAAC;IAC/B,qCAAqC;IACrC,MAAM,CAAC,EAAE,WAAW,CAAC;IACrB,+CAA+C;IAC/C,cAAc,CAAC,EAAE,aAAa,CAAC,OAAO,CAAC,CAAC;IACxC,mEAAmE;IACnE,QAAQ,CAAC,EAAE,aAAa,CAAC,MAAM,CAAC,CAAC;IACjC,uCAAuC;IACvC,IAAI,CAAC,EAAE,aAAa,CAAC,QAAQ,CAAC,CAAC;IAC/B,qDAAqD;IACrD,OAAO,CAAC,EAAE,aAAa,CAAC,OAAO,CAAC,CAAC;CAClC;AAED;;;;;GAKG;AACH,wBAAgB,SAAS,CAAC,OAAO,EAAE,OAAO,GAAG,OAAO,IAAI,YAAY,CAInE;AAED;;;;GAIG;AACH,MAAM,WAAW,gBAAiB,SAAQ,UAAU;IAClD,yDAAyD;IACzD,IAAI,EAAE,cAAc,CAAC;IACrB,+CAA+C;IAC/C,cAAc,CAAC,EAAE,aAAa,CAAC,OAAO,CAAC,CAAC;IACxC,kFAAkF;IAClF,QAAQ,CAAC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;;GAIG;AACH,MAAM,WAAW,gBAAiB,SAAQ,UAAU;IAClD,yDAAyD;IACzD,IAAI,EAAE,cAAc,CAAC;IACrB,+CAA+C;IAC/C,cAAc,CAAC,EAAE,aAAa,CAAC,OAAO,CAAC,CAAC;IACxC,kFAAkF;IAClF,QAAQ,CAAC,EAAE,aAAa,CAAC,MAAM,CAAC,CAAC;IACjC,mFAAmF;IACnF,kBAAkB,CAAC,EAAE,aAAa,CAAC,MAAM,CAAC,CAAC;CAC5C;AAED;;;;;GAKG;AACH,wBAAgB,aAAa,CAAC,OAAO,EAAE,OAAO,GAAG,OAAO,IAAI,gBAAgB,CAM3E"}
@@ -1 +1 @@
1
- {"version":3,"file":"article.js","sourceRoot":"","sources":["../../src/types/article.ts"],"names":[],"mappings":"AA+BA;;;;;GAKG;AACH,MAAM,UAAU,SAAS,CAAC,OAAgB;IACxC,OAAO,CACL,OAAO,OAAO,KAAK,QAAQ,IAAI,OAAO,KAAK,IAAI,IAAK,OAAwB,CAAC,IAAI,KAAK,SAAS,CAChG,CAAC;AACJ,CAAC;AAkBD;;;;;GAKG;AACH,MAAM,UAAU,aAAa,CAAC,OAAgB;IAC5C,OAAO,CACL,OAAO,OAAO,KAAK,QAAQ;QAC3B,OAAO,KAAK,IAAI;QACf,OAA4B,CAAC,IAAI,KAAK,cAAc,CACtD,CAAC;AACJ,CAAC"}
1
+ {"version":3,"file":"article.js","sourceRoot":"","sources":["../../src/types/article.ts"],"names":[],"mappings":"AAwCA;;;;;GAKG;AACH,MAAM,UAAU,SAAS,CAAC,OAAgB;IACxC,OAAO,CACL,OAAO,OAAO,KAAK,QAAQ,IAAI,OAAO,KAAK,IAAI,IAAK,OAAwB,CAAC,IAAI,KAAK,SAAS,CAChG,CAAC;AACJ,CAAC;AAkBD;;;;;GAKG;AACH,MAAM,UAAU,aAAa,CAAC,OAAgB;IAC5C,OAAO,CACL,OAAO,OAAO,KAAK,QAAQ;QAC3B,OAAO,KAAK,IAAI;QACf,OAA4B,CAAC,IAAI,KAAK,cAAc,CACtD,CAAC;AACJ,CAAC"}
package/docs/llms.md CHANGED
@@ -28,8 +28,13 @@ interface IBasePage {
28
28
 
29
29
  ### Article
30
30
  ```ts
31
- import type { IBaseArticle, IBaseArticleType } from '@se-studio/core-data-types';
31
+ import type { IBaseArticle, IBaseArticleType, IDownloadAsset } from '@se-studio/core-data-types';
32
32
  import { isArticle, isArticleType } from '@se-studio/core-data-types';
33
+
34
+ interface IBaseArticle {
35
+ // ...
36
+ download?: IDownloadAsset; // optional downloadable asset (e.g. PDF), proxied via urlCalculators.download
37
+ }
33
38
  ```
34
39
 
35
40
  ### Tag
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@se-studio/core-data-types",
3
- "version": "1.0.165",
3
+ "version": "1.0.166",
4
4
  "description": "Core TypeScript type definitions for SE Studio content models",
5
5
  "repository": {
6
6
  "type": "git",