@symbiote-native/cellular 1.0.0 → 3.0.0

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.
Files changed (2) hide show
  1. package/README.md +38 -27
  2. package/package.json +14 -14
package/README.md CHANGED
@@ -17,6 +17,10 @@ depends on) — every function is hand-ported into this package's own `core/`.
17
17
  npm install @symbiote-native/cellular
18
18
  ```
19
19
 
20
+ Scaffolding or extending a SymbioteNative app? `npx @symbiote-native/cli new --cellular` (or
21
+ `add --cellular` in an existing app) installs and wires this for you — see
22
+ [`@symbiote-native/cli`](../cli).
23
+
20
24
  Depends on `expo-cellular` and `expo-modules-core` directly (regular dependencies, pinned to
21
25
  exact versions — never a caret range, since this package's `core/` is hand-ported against one
22
26
  specific native API shape and a newer resolve could silently drift the two apart). Never install
@@ -89,12 +93,12 @@ function CellularScreen() {
89
93
 
90
94
  return (
91
95
  <>
92
- <Text>
96
+ <text>
93
97
  {generation === null ? 'checking…' : CellularGeneration[generation]}
94
- </Text>
95
- <Text>{carrierName ?? 'checking…'}</Text>
96
- <Text>{status === null ? 'checking…' : status.status}</Text>
97
- <Button title="Request permission" onPress={() => requestPermission()} />
98
+ </text>
99
+ <text>{carrierName ?? 'checking…'}</text>
100
+ <text>{status === null ? 'checking…' : status.status}</text>
101
+ <button title="Request permission" onPress={() => requestPermission()} />
98
102
  </>
99
103
  );
100
104
  }
@@ -125,12 +129,12 @@ onMounted(() => {
125
129
  });
126
130
  </script>
127
131
  <template>
128
- <Text>{{
132
+ <text>{{
129
133
  generation === null ? 'checking…' : CellularGeneration[generation]
130
- }}</Text>
131
- <Text>{{ carrierName ?? 'checking…' }}</Text>
132
- <Text>{{ status === null ? 'checking…' : status.status }}</Text>
133
- <Button title="Request permission" :onPress="() => requestPermission()" />
134
+ }}</text>
135
+ <text>{{ carrierName ?? 'checking…' }}</text>
136
+ <text>{{ status === null ? 'checking…' : status.status }}</text>
137
+ <button title="Request permission" :onPress="() => requestPermission()" />
134
138
  </template>
135
139
  ```
136
140
 
@@ -156,10 +160,13 @@ onMounted(() => {
156
160
  );
157
161
  </script>
158
162
 
159
- <Text>{generation === null ? 'checking…' : CellularGeneration[generation]}</Text>
160
- <Text>{carrierName ?? 'checking…'}</Text>
161
- <Text>{permissions.status === null ? 'checking…' : permissions.status.status}</Text>
162
- <Button title="Request permission" onPress={() => permissions.request()} />
163
+ <text>{generation === null ? 'checking…' : CellularGeneration[generation]}</text
164
+ >
165
+ <text>{carrierName ?? 'checking…'}</text>
166
+ <text
167
+ >{permissions.status === null ? 'checking…' : permissions.status.status}</text
168
+ >
169
+ <button title="Request permission" onPress={() => permissions.request()} />
163
170
  ```
164
171
 
165
172
  ```tsx
@@ -173,7 +180,9 @@ import {
173
180
  import { createPermissions } from '@symbiote-native/cellular/solid';
174
181
 
175
182
  function CellularScreen() {
176
- const [generation, setGeneration] = createSignal<CellularGeneration | null>(null);
183
+ const [generation, setGeneration] = createSignal<CellularGeneration | null>(
184
+ null,
185
+ );
177
186
  const [carrierName, setCarrierName] = createSignal<string | null>(null);
178
187
  const { status, request: requestPermission } = createPermissions();
179
188
 
@@ -186,12 +195,14 @@ function CellularScreen() {
186
195
 
187
196
  return (
188
197
  <>
189
- <Text>
190
- {generation() === null ? 'checking…' : CellularGeneration[generation()!]}
191
- </Text>
192
- <Text>{carrierName() ?? 'checking…'}</Text>
193
- <Text>{status() === null ? 'checking…' : status()!.status}</Text>
194
- <Button title="Request permission" onPress={() => requestPermission()} />
198
+ <text>
199
+ {generation() === null
200
+ ? 'checking…'
201
+ : CellularGeneration[generation()!]}
202
+ </text>
203
+ <text>{carrierName() ?? 'checking…'}</text>
204
+ <text>{status() === null ? 'checking…' : status()!.status}</text>
205
+ <button title="Request permission" onPress={() => requestPermission()} />
195
206
  </>
196
207
  );
197
208
  }
@@ -210,15 +221,15 @@ import {
210
221
  @Component({
211
222
  selector: 'CellularScreen',
212
223
  template: `
213
- <Text>{{
224
+ <text>{{
214
225
  generation() === null ? 'checking…' : CellularGeneration[generation()!]
215
- }}</Text>
216
- <Text>{{ carrierName() ?? 'checking…' }}</Text>
217
- <Text>{{ permissionStatus()?.status ?? 'checking…' }}</Text>
218
- <Button
226
+ }}</text>
227
+ <text>{{ carrierName() ?? 'checking…' }}</text>
228
+ <text>{{ permissionStatus()?.status ?? 'checking…' }}</text>
229
+ <button
219
230
  title="Request permission"
220
231
  (press)="permissionsService.request()"
221
- ></Button>
232
+ ></button>
222
233
  `,
223
234
  })
224
235
  export class CellularScreen {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@symbiote-native/cellular",
3
- "version": "1.0.0",
3
+ "version": "3.0.0",
4
4
  "description": "expo-cellular wrapped for SymbioteNative — one framework-agnostic core, built once and reachable from the React, Vue, Svelte, Solid, and Angular adapters. Cellular generation (2G/3G/4G/5G), carrier/SIM info on Android (ISO country code, carrier name, MCC/MNC), VoIP-support detection, and the permission get/request pair gating carrier info on Android.",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -80,12 +80,12 @@
80
80
  "solid-js": ">=1.9.0",
81
81
  "svelte": ">=5.56.0",
82
82
  "vue": ">=3.5.0",
83
- "@symbiote-native/angular": "^1.0.0",
84
- "@symbiote-native/engine": "^0.4.0",
85
- "@symbiote-native/react": "^1.0.0",
86
- "@symbiote-native/solid": "^1.0.0",
87
- "@symbiote-native/svelte": "^1.0.0",
88
- "@symbiote-native/vue": "^1.0.0"
83
+ "@symbiote-native/angular": "^3.0.0",
84
+ "@symbiote-native/engine": "^1.0.0",
85
+ "@symbiote-native/react": "^3.0.0",
86
+ "@symbiote-native/solid": "^3.0.0",
87
+ "@symbiote-native/svelte": "^3.0.0",
88
+ "@symbiote-native/vue": "^3.0.0"
89
89
  },
90
90
  "peerDependenciesMeta": {
91
91
  "@symbiote-native/angular": {
@@ -133,13 +133,13 @@
133
133
  "solid-js": "^1.9.14",
134
134
  "svelte": "^5.56.0",
135
135
  "typescript": "~6.0.0",
136
- "@symbiote-native/angular": "1.0.0",
137
- "@symbiote-native/engine": "0.4.0",
138
- "@symbiote-native/react": "1.0.0",
139
- "@symbiote-native/solid": "1.0.0",
140
- "@symbiote-native/svelte": "1.0.0",
141
- "@symbiote-native/test-utils": "0.3.0",
142
- "@symbiote-native/vue": "1.0.0"
136
+ "@symbiote-native/angular": "3.0.0",
137
+ "@symbiote-native/engine": "1.0.0",
138
+ "@symbiote-native/react": "3.0.0",
139
+ "@symbiote-native/solid": "3.0.0",
140
+ "@symbiote-native/svelte": "3.0.0",
141
+ "@symbiote-native/test-utils": "0.3.1",
142
+ "@symbiote-native/vue": "3.0.0"
143
143
  },
144
144
  "scripts": {
145
145
  "typecheck": "tsc --build",