@ctx-core/window 14.0.28 → 14.0.29
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 +6 -0
- package/COMMIT_EDITMSG +1 -0
- package/package.json +2 -2
- package/src/hostname$_.d.ts +2 -2
- package/src/hostname$_.js +2 -2
- package/src/pathname$_.d.ts +2 -2
- package/src/pathname$_.js +2 -2
- package/src/window_location$_.d.ts +2 -2
- package/src/window_location$_.js +3 -3
- package/src/window_location_hostname$_.d.ts +2 -2
- package/src/window_location_hostname$_.js +2 -2
- package/src/window_location_pathname$_.d.ts +2 -2
- package/src/window_location_pathname$_.js +2 -2
package/CHANGELOG.md
CHANGED
package/COMMIT_EDITMSG
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ctx-core/window",
|
|
3
|
-
"version": "14.0.
|
|
3
|
+
"version": "14.0.29",
|
|
4
4
|
"description": "ctx-core window",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"ctx-core",
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
"dependencies": {
|
|
27
27
|
"@ctx-core/dom": "^11.1.21",
|
|
28
28
|
"@ctx-core/function": "^20.8.0",
|
|
29
|
-
"@ctx-core/nanostores": "^1.
|
|
29
|
+
"@ctx-core/nanostores": "^1.2.0",
|
|
30
30
|
"@ctx-core/object": "^22.2.0"
|
|
31
31
|
},
|
|
32
32
|
"devDependencies": {
|
package/src/hostname$_.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { WritableAtom_ } from '@ctx-core/nanostores'
|
|
2
2
|
import { B } from '@ctx-core/object'
|
|
3
3
|
export declare const hostname$_:B<hostname$_T>
|
|
4
|
-
export declare type hostname$_T =
|
|
4
|
+
export declare type hostname$_T = WritableAtom_<string|undefined>;
|
package/src/hostname$_.js
CHANGED
package/src/pathname$_.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { WritableAtom_ } from '@ctx-core/nanostores'
|
|
2
2
|
import { B } from '@ctx-core/object'
|
|
3
3
|
export declare const pathname$_:B<pathname$_T>
|
|
4
|
-
export declare type pathname$_T =
|
|
4
|
+
export declare type pathname$_T = WritableAtom_<string|undefined>;
|
|
5
5
|
export { pathname$_ as b__pathname }
|
package/src/pathname$_.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { WritableAtom_ } from '@ctx-core/nanostores'
|
|
2
2
|
import { B } from '@ctx-core/object'
|
|
3
3
|
export declare const window_location$_:B<window_location$_T>
|
|
4
|
-
export interface window_location$_T extends
|
|
4
|
+
export interface window_location$_T extends WritableAtom_<Location|undefined> {
|
|
5
5
|
reset_window_location:()=>void;
|
|
6
6
|
}
|
package/src/window_location$_.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { has_dom } from '@ctx-core/dom'
|
|
2
|
-
import {
|
|
2
|
+
import { atom_ } from '@ctx-core/nanostores'
|
|
3
3
|
import { assign, be_ } from '@ctx-core/object'
|
|
4
4
|
export const window_location$_ = be_('window_location$', ()=>{
|
|
5
|
-
const window_location$ =
|
|
6
|
-
const window_location_reload_popstate_bound$ =
|
|
5
|
+
const window_location$ = atom_(undefined)
|
|
6
|
+
const window_location_reload_popstate_bound$ = atom_(undefined)
|
|
7
7
|
if (has_dom) {
|
|
8
8
|
reset_window_location()
|
|
9
9
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { ReadableAtom_ } from '@ctx-core/nanostores'
|
|
2
2
|
import { B } from '@ctx-core/object'
|
|
3
3
|
export declare const window_location_hostname$_:B<window_location_hostname$_T>
|
|
4
|
-
export declare type window_location_hostname$_T =
|
|
4
|
+
export declare type window_location_hostname$_T = ReadableAtom_<string|undefined>;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { computed_ } from '@ctx-core/nanostores'
|
|
2
2
|
import { be_ } from '@ctx-core/object'
|
|
3
3
|
import { hostname$_ } from './hostname$_.js'
|
|
4
4
|
import { window_location$_ } from './window_location$_.js'
|
|
5
|
-
export const window_location_hostname$_ = be_('window_location_hostname$', (ctx)=>
|
|
5
|
+
export const window_location_hostname$_ = be_('window_location_hostname$', (ctx)=>computed_([
|
|
6
6
|
hostname$_(ctx),
|
|
7
7
|
window_location$_(ctx),
|
|
8
8
|
], (hostname, window_location)=>
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { ReadableAtom_ } from '@ctx-core/nanostores'
|
|
2
2
|
import { B } from '@ctx-core/object'
|
|
3
3
|
export declare const window_location_pathname$_:B<window_location_pathname$_T>
|
|
4
4
|
export declare type window_location_pathname_T = string|undefined;
|
|
5
|
-
export declare type window_location_pathname$_T =
|
|
5
|
+
export declare type window_location_pathname$_T = ReadableAtom_<window_location_pathname_T>;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { computed_ } from '@ctx-core/nanostores'
|
|
2
2
|
import { be_ } from '@ctx-core/object'
|
|
3
3
|
import { pathname$_ } from './pathname$_.js'
|
|
4
4
|
import { window_location$_ } from './window_location$_.js'
|
|
5
|
-
export const window_location_pathname$_ = be_('window_location_pathname$', (ctx)=>
|
|
5
|
+
export const window_location_pathname$_ = be_('window_location_pathname$', (ctx)=>computed_([
|
|
6
6
|
pathname$_(ctx),
|
|
7
7
|
window_location$_(ctx),
|
|
8
8
|
], (pathname, location__window)=>
|