@soltech/fluid-common 1.4.2 → 1.4.3

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/AGENTS.md CHANGED
@@ -3,6 +3,7 @@
3
3
  Read this entire file before every task.
4
4
 
5
5
  ## Agent Rules & Safety
6
+ - Never edit any files when the current git branch is `main` — always work on a feature branch. Run `git branch --show-current` to confirm before making any changes.
6
7
  - Never touch `.env*`, `certs/` or any file containing secrets/credentials.
7
8
  - Never introduce new dependencies without asking first.
8
9
  - Never rewrite large parts of the codebase unless explicitly requested.
@@ -17,7 +18,18 @@ Read this entire file before every task.
17
18
  ## Build, Dev & Validation
18
19
  - Build: `npm run build`
19
20
  - Lint: `npm run lint`
20
- - Publish: `npm run pub` (build + publish + push)
21
+ - Publish: see Publishing Flow below
22
+
23
+ ### Publishing Flow
24
+ The correct sequence before publishing a new version:
25
+ 1. Make all code changes to `src/index.ts`.
26
+ 2. Bump `version` in `package.json`.
27
+ 3. Run `npm i` (updates `package-lock.json`).
28
+ 4. Commit all changes (`src/index.ts`, `package.json`, `package-lock.json`).
29
+ 5. Push the commit: `git push`.
30
+ 6. Publish to npm: `npm publish` (this runs `npm run build` first via the `pub` script, or run `npm run build && npm publish` directly).
31
+
32
+ Do **not** use `npm run pub` as a single command — it pushes *after* publishing, which means npm gets the package before git has a clean commit.
21
33
 
22
34
  Before final proposal on code changes:
23
35
  1. Run `npm run lint`.
@@ -41,3 +53,8 @@ When creating PRs, always include a Shortcut ticket reference in the PR body usi
41
53
  ```
42
54
  [sc-17649](https://app.shortcut.com/soltech/story/17649/ticket-title-slug)
43
55
  ```
56
+
57
+ ### PR description scope
58
+
59
+ - The PR description must reflect **all changes in the branch**, not just the most recent commit. Run `git log main..HEAD` and review the full diff before writing or updating the description.
60
+ - When a ticket spans multiple repos (e.g. a type/enum change here in `fluid-common` that also requires updates in `fluid-api`, `fluid-widget`, or `fluid-payments`), list the related repos and their PRs in the description so reviewers have the full picture. Name each repo, briefly describe what changed, and cross-link the corresponding PRs.
package/lib/index.d.ts CHANGED
@@ -20,6 +20,11 @@ export declare enum PaymentType {
20
20
  CRYPTO = "Crypto",
21
21
  EWALLET = "EWallet"
22
22
  }
23
+ export declare enum WindowRedirectType {
24
+ POPUP_WINDOW = "popupWindow",
25
+ BROWSER_TAB = "browserTab",
26
+ NONE = "none"
27
+ }
23
28
  export interface WalletRequestBody {
24
29
  payload?: object | string;
25
30
  payloadOptions?: TransactionOptions;
@@ -115,7 +120,7 @@ export interface PaymentMethod {
115
120
  bonusCodes?: string[];
116
121
  instructions?: string;
117
122
  fees?: PaymentMethodFees;
118
- popupWindowRedirect: boolean;
123
+ windowRedirectType?: WindowRedirectType;
119
124
  voucherAmounts?: number[];
120
125
  depositHandledByHostSite?: boolean;
121
126
  withdrawalHandledByHostSite?: boolean;
package/lib/index.js CHANGED
@@ -24,6 +24,12 @@ export var PaymentType;
24
24
  PaymentType["CRYPTO"] = "Crypto";
25
25
  PaymentType["EWALLET"] = "EWallet";
26
26
  })(PaymentType || (PaymentType = {}));
27
+ export var WindowRedirectType;
28
+ (function (WindowRedirectType) {
29
+ WindowRedirectType["POPUP_WINDOW"] = "popupWindow";
30
+ WindowRedirectType["BROWSER_TAB"] = "browserTab";
31
+ WindowRedirectType["NONE"] = "none";
32
+ })(WindowRedirectType || (WindowRedirectType = {}));
27
33
  export var EncryptionType;
28
34
  (function (EncryptionType) {
29
35
  EncryptionType["NO_ENCRYPTION"] = "NO_ENCRYPTION";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@soltech/fluid-common",
3
- "version": "1.4.2",
3
+ "version": "1.4.3",
4
4
  "type": "module",
5
5
  "description": "Fluid frontend, API and AI common interfaces & enums",
6
6
  "main": "lib/index.js",
package/src/index.ts CHANGED
@@ -24,6 +24,12 @@ export enum PaymentType {
24
24
  EWALLET = 'EWallet'
25
25
  }
26
26
 
27
+ export enum WindowRedirectType {
28
+ POPUP_WINDOW = 'popupWindow',
29
+ BROWSER_TAB = 'browserTab',
30
+ NONE = 'none'
31
+ }
32
+
27
33
  export interface WalletRequestBody {
28
34
  payload?: object | string;
29
35
  payloadOptions?: TransactionOptions;
@@ -129,7 +135,7 @@ export interface PaymentMethod {
129
135
  bonusCodes?: string[];
130
136
  instructions?: string;
131
137
  fees?: PaymentMethodFees;
132
- popupWindowRedirect: boolean;
138
+ windowRedirectType?: WindowRedirectType;
133
139
  voucherAmounts?: number[];
134
140
  depositHandledByHostSite?: boolean;
135
141
  withdrawalHandledByHostSite?: boolean;