@flaxia/node 0.3.6 → 0.3.7
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/README.md
CHANGED
|
@@ -84,6 +84,18 @@ controller.clearConsent() // 同意・拒否・失効時刻をすべて消去
|
|
|
84
84
|
同意は localStorage に保存され、**30日**で失効します。`grant` と `deny` は排他で、
|
|
85
85
|
片方を保存するともう片方は消去されます。
|
|
86
86
|
|
|
87
|
+
### 保存状態の読み取り(ノード初期化前)
|
|
88
|
+
|
|
89
|
+
`getFlaxiaNodeConsentState()` はコントローラを作らず、ネットワークにも触れず、
|
|
90
|
+
保存済みの同意状態だけを同期的に返します。設定画面をノード初期化前に描画する
|
|
91
|
+
ホストはこれを使えます。
|
|
92
|
+
|
|
93
|
+
```typescript
|
|
94
|
+
import { getFlaxiaNodeConsentState } from '@flaxia/node'
|
|
95
|
+
|
|
96
|
+
getFlaxiaNodeConsentState() // 'unset' | 'granted' | 'denied'
|
|
97
|
+
```
|
|
98
|
+
|
|
87
99
|
## アーキテクチャ
|
|
88
100
|
|
|
89
101
|
```
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"public-api.test.d.ts","sourceRoot":"","sources":["../../src/__tests__/public-api.test.ts"],"names":[],"mappings":""}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { initFlaxiaNode } from './client/SignalingClient';
|
|
2
|
+
export { getConsentState as getFlaxiaNodeConsentState } from './consent/storage';
|
|
2
3
|
export { initFlaxiaNode };
|
|
3
4
|
export type { ConsentControls, ConsentState, FlaxiaNodeController } from '@flaxia/sdk';
|
|
4
5
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAK1D,OAAO,EAAE,eAAe,IAAI,yBAAyB,EAAE,MAAM,mBAAmB,CAAC;AACjF,OAAO,EAAE,cAAc,EAAE,CAAC;AAC1B,YAAY,EAAE,eAAe,EAAE,YAAY,EAAE,oBAAoB,EAAE,MAAM,aAAa,CAAC"}
|
package/dist/index.js
CHANGED