diff --git a/.github/ISSUE_TEMPLATE/1-bug-report.yaml b/.github/ISSUE_TEMPLATE/1-bug-report.yaml index 6d92e1f19..433fb8ec3 100644 --- a/.github/ISSUE_TEMPLATE/1-bug-report.yaml +++ b/.github/ISSUE_TEMPLATE/1-bug-report.yaml @@ -8,7 +8,7 @@ body: id: affected-packages attributes: label: Package(s) - description: Which @vatr/* package(s) are the source of the bug? + description: Which @alwatr/* package(s) are the source of the bug? options: - fetch - logger @@ -54,21 +54,21 @@ body: - type: textarea id: registeredList attributes: - label: Vatr registered list - description: Please provide the Vatr registered list by running `console.log(JSON.stringify(window.Vatr.registeredList, null, 2));` in the browser console. + label: Alwatr registered list + description: Please provide the Alwatr registered list by running `console.log(JSON.stringify(window.Alwatr.registeredList, null, 2));` in the browser console. render: console placeholder: | [ { - "name": "@vatr/logger", + "name": "@alwatr/logger", "version": "1.2.3" }, { - "name": "@vatr/signal", + "name": "@alwatr/signal", "version": "1.2.3" }, { - "name": "@vatr/router", + "name": "@alwatr/router", "version": "1.2.3" } ] diff --git a/.github/ISSUE_TEMPLATE/2-feature-request.yaml b/.github/ISSUE_TEMPLATE/2-feature-request.yaml index d3279066d..6892cb794 100644 --- a/.github/ISSUE_TEMPLATE/2-feature-request.yaml +++ b/.github/ISSUE_TEMPLATE/2-feature-request.yaml @@ -6,7 +6,7 @@ body: id: affected-packages attributes: label: Package(s) - description: Which @vatr/* package(s) are the source of the bug? + description: Which @alwatr/* package(s) are the source of the bug? options: - fetch - logger diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md index 9d675ede9..53729bee8 100644 --- a/.github/pull_request_template.md +++ b/.github/pull_request_template.md @@ -9,7 +9,7 @@ Fixes #(issue) Please check if your PR fulfills the following requirements: - [ ] Open an issue for bug report or feature request and mention it to this PR. -- [ ] The commit message follows our guidelines: +- [ ] The commit message follows our guidelines: - [ ] All methods have proper description in `jsdocs` format with `@example` section. - [ ] Docs have been added / updated (for bug fixes / features). - [ ] I have performed a self-review of my own code. diff --git a/.vscode/settings.json b/.vscode/settings.json index cc55f9b34..43a6c1d37 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -10,13 +10,13 @@ }, "cSpell.language": "en,fa", "cSpell.words": [ - "alvatr", + "alwatr", "khafan", "mastmalize", "Mihandoost", "noncallable", "tsbuildinfo", - "Vatr" + "Alwatr" ], "typescript.tsdk": "node_modules\\typescript\\lib", "files.exclude": { diff --git a/CHANGELOG.md b/CHANGELOG.md index d884f2127..99e27bfa4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,192 +3,192 @@ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. -# [0.5.0](https://github.com/AliMD/One/compare/v0.4.0...v0.5.0) (2022-03-11) +# [0.5.0](https://github.com/AliMD/alwatr/compare/v0.4.0...v0.5.0) (2022-03-11) ### Bug Fixes -* **signal:** disabled getter and optional dispatch options ([28ced3d](https://github.com/AliMD/One/commit/28ced3d0c4cdf44fc2aebfab98db0883fc5363fe)) -* **wordflows:** tests on all branches ([5cca930](https://github.com/AliMD/One/commit/5cca930f3adf88624c6ff7a1f3c551502f7a4826)) +* **signal:** disabled getter and optional dispatch options ([28ced3d](https://github.com/AliMD/alwatr/commit/28ced3d0c4cdf44fc2aebfab98db0883fc5363fe)) +* **wordflows:** tests on all branches ([5cca930](https://github.com/AliMD/alwatr/commit/5cca930f3adf88624c6ff7a1f3c551502f7a4826)) ### Features -* **signal:** new SignalInterface ([221701a](https://github.com/AliMD/One/commit/221701a54ea9edda4a3a935a7b098e235ec52691)) -* **workflow:** add tests workflow ([7512aba](https://github.com/AliMD/One/commit/7512abae92add3fe73a0578d55f9439f7d1632af)) -* **workflow:** add verify workflow ([88fc40c](https://github.com/AliMD/One/commit/88fc40ce9affeaf715fc8dda600f35fa7b2c84b6)) -* **workflow:** rename workflow file ([e35df8f](https://github.com/AliMD/One/commit/e35df8fac972b7b4dc81dfac159d97d09b0b6751)) +* **signal:** new SignalInterface ([221701a](https://github.com/AliMD/alwatr/commit/221701a54ea9edda4a3a935a7b098e235ec52691)) +* **workflow:** add tests workflow ([7512aba](https://github.com/AliMD/alwatr/commit/7512abae92add3fe73a0578d55f9439f7d1632af)) +* **workflow:** add verify workflow ([88fc40c](https://github.com/AliMD/alwatr/commit/88fc40ce9affeaf715fc8dda600f35fa7b2c84b6)) +* **workflow:** rename workflow file ([e35df8f](https://github.com/AliMD/alwatr/commit/e35df8fac972b7b4dc81dfac159d97d09b0b6751)) ### Performance Improvements -* **logger:** refactor making logger object ([bc38018](https://github.com/AliMD/One/commit/bc38018758540130df2f46c44521aea0a867bbe8)) +* **logger:** refactor making logger object ([bc38018](https://github.com/AliMD/alwatr/commit/bc38018758540130df2f46c44521aea0a867bbe8)) -# [0.4.0](https://github.com/AliMD/One/compare/v0.3.0...v0.4.0) (2022-03-11) +# [0.4.0](https://github.com/AliMD/alwatr/compare/v0.3.0...v0.4.0) (2022-03-11) ### Bug Fixes -* **fetch:** build issue [#73](https://github.com/AliMD/One/issues/73) ([fb74463](https://github.com/AliMD/One/commit/fb74463d367393706d16e482488a565bdfef70a1)) -* **i18n:** build issue [#75](https://github.com/AliMD/One/issues/75) ([fe7a108](https://github.com/AliMD/One/commit/fe7a108904176e63b8aa7e388d95ee8a90c6b71f)) -* **logger:** types missing ([712363d](https://github.com/AliMD/One/commit/712363d3cf77a712f8c801c4dc9d06d256dfc0e6)) -* **pr-template:** make it simple ([3f4253b](https://github.com/AliMD/One/commit/3f4253b3a44634e5440fe714937536fa18fa9b7a)) -* **router:** build issue for parameterList type [#75](https://github.com/AliMD/One/issues/75) ([5fc1ecd](https://github.com/AliMD/One/commit/5fc1ecd12b938936e2718f9307186493e2712e1f)) -* **tsconfig:** add useDefineForClassFields ([cf11de2](https://github.com/AliMD/One/commit/cf11de28d032e23aaac39b01a4a6f863b8fa13b8)) +* **fetch:** build issue [#73](https://github.com/AliMD/alwatr/issues/73) ([fb74463](https://github.com/AliMD/alwatr/commit/fb74463d367393706d16e482488a565bdfef70a1)) +* **i18n:** build issue [#75](https://github.com/AliMD/alwatr/issues/75) ([fe7a108](https://github.com/AliMD/alwatr/commit/fe7a108904176e63b8aa7e388d95ee8a90c6b71f)) +* **logger:** types missing ([712363d](https://github.com/AliMD/alwatr/commit/712363d3cf77a712f8c801c4dc9d06d256dfc0e6)) +* **pr-template:** make it simple ([3f4253b](https://github.com/AliMD/alwatr/commit/3f4253b3a44634e5440fe714937536fa18fa9b7a)) +* **router:** build issue for parameterList type [#75](https://github.com/AliMD/alwatr/issues/75) ([5fc1ecd](https://github.com/AliMD/alwatr/commit/5fc1ecd12b938936e2718f9307186493e2712e1f)) +* **tsconfig:** add useDefineForClassFields ([cf11de2](https://github.com/AliMD/alwatr/commit/cf11de28d032e23aaac39b01a4a6f863b8fa13b8)) ### Features -* **logger:** add logProperty, logMethodFull ([8b0317d](https://github.com/AliMD/One/commit/8b0317db88ed73604a27935a3a30cd5c31cb0804)) -* **logger:** complete refactor the logger with new API and fix show correct line number ([7efe8cf](https://github.com/AliMD/One/commit/7efe8cf0f566e148406f38fdd60fa3d747c9bc51)) +* **logger:** add logProperty, logMethodFull ([8b0317d](https://github.com/AliMD/alwatr/commit/8b0317db88ed73604a27935a3a30cd5c31cb0804)) +* **logger:** complete refactor the logger with new API and fix show correct line number ([7efe8cf](https://github.com/AliMD/alwatr/commit/7efe8cf0f566e148406f38fdd60fa3d747c9bc51)) -# [0.3.0](https://github.com/AliMD/One/compare/v0.2.1...v0.3.0) (2022-03-06) +# [0.3.0](https://github.com/AliMD/alwatr/compare/v0.2.1...v0.3.0) (2022-03-06) ### Bug Fixes -* **signal:** signal provider type ([0151c57](https://github.com/AliMD/One/commit/0151c57d9b6d4f7e83bb9b1847ebe0ae53cd8f89)) +* **signal:** signal provider type ([0151c57](https://github.com/AliMD/alwatr/commit/0151c57d9b6d4f7e83bb9b1847ebe0ae53cd8f89)) ### Features -* **i18n:** impeliment core methods ([6449bb4](https://github.com/AliMD/One/commit/6449bb42837335c2e2e5b4a75e98139528e2e7da)) -* **i18n:** impeliment initialI18n ([87da5e4](https://github.com/AliMD/One/commit/87da5e46943ba12a8067fcac06c1dcced1e6fb92)) -* **i18n:** localize method ([544edfd](https://github.com/AliMD/One/commit/544edfdd1bc52befab6afe4cbfb62ce1638aff2d)) -* **i18n:** start new package for i18n/l10n ([88a6c28](https://github.com/AliMD/One/commit/88a6c28ad038ed02ca45128378e669f6d9c6949d)) +* **i18n:** impeliment core methods ([6449bb4](https://github.com/AliMD/alwatr/commit/6449bb42837335c2e2e5b4a75e98139528e2e7da)) +* **i18n:** impeliment initialI18n ([87da5e4](https://github.com/AliMD/alwatr/commit/87da5e46943ba12a8067fcac06c1dcced1e6fb92)) +* **i18n:** localize method ([544edfd](https://github.com/AliMD/alwatr/commit/544edfdd1bc52befab6afe4cbfb62ce1638aff2d)) +* **i18n:** start new package for i18n/l10n ([88a6c28](https://github.com/AliMD/alwatr/commit/88a6c28ad038ed02ca45128378e669f6d9c6949d)) -## [0.2.1](https://github.com/AliMD/One/compare/v0.2.0...v0.2.1) (2022-03-05) +## [0.2.1](https://github.com/AliMD/alwatr/compare/v0.2.0...v0.2.1) (2022-03-05) ### Bug Fixes -* **logger:** vatrRegisteredList name ([ff59133](https://github.com/AliMD/One/commit/ff5913321c4eafa1ce53fdacebf8fb4f23bfe430)) -* **signal:** signal value type issue ([292a4a7](https://github.com/AliMD/One/commit/292a4a7d12a2fd143761e67cd1ecd2e5e40f2ee9)) +* **logger:** alwatrRegisteredList name ([ff59133](https://github.com/AliMD/alwatr/commit/ff5913321c4eafa1ce53fdacebf8fb4f23bfe430)) +* **signal:** signal value type issue ([292a4a7](https://github.com/AliMD/alwatr/commit/292a4a7d12a2fd143761e67cd1ecd2e5e40f2ee9)) ### Features -* **issue-template:** bug report and feqture request form template ([77159a7](https://github.com/AliMD/One/commit/77159a7076369781cfcf7167e58843e0fb25fa18)) +* **issue-template:** bug report and feqture request form template ([77159a7](https://github.com/AliMD/alwatr/commit/77159a7076369781cfcf7167e58843e0fb25fa18)) -# [0.2.0](https://github.com/AliMD/One/compare/v0.1.2...v0.2.0) (2022-03-05) +# [0.2.0](https://github.com/AliMD/alwatr/compare/v0.1.2...v0.2.0) (2022-03-05) ### Bug Fixes -* **fetch:** error codes ([4e0be80](https://github.com/AliMD/One/commit/4e0be80786b6667035ae82750f2351bd2da4f341)) -* **router:** rename setSignalProvider callback detail to requestParam ([6e09f87](https://github.com/AliMD/One/commit/6e09f8772d320625fb4c15ccaa0abcfa2932f992)) -* **router:** rename setSignalProvider callback detail to requestParam ([070c0f6](https://github.com/AliMD/One/commit/070c0f6c5e4d6994e9af19dca515acc4f7ad4c5a)) -* **router:** trigger click signal name ([b4a9477](https://github.com/AliMD/One/commit/b4a9477464cb05bb8fa227014de5e8af5b8dd600)) -* **signal:** fix dispatchSignal value parameters ([4d34cfb](https://github.com/AliMD/One/commit/4d34cfbb5281d5ce4a4f06ddaaf72218dde80cdd)) -* **tsconfig:** add router ([a107e08](https://github.com/AliMD/One/commit/a107e0872d59484ec208640b678e65212add53f0)) -* **util:** remove package ([b337d9a](https://github.com/AliMD/One/commit/b337d9a97c8f73c2a87e722b23a50718321d1648)) +* **fetch:** error codes ([4e0be80](https://github.com/AliMD/alwatr/commit/4e0be80786b6667035ae82750f2351bd2da4f341)) +* **router:** rename setSignalProvider callback detail to requestParam ([6e09f87](https://github.com/AliMD/alwatr/commit/6e09f8772d320625fb4c15ccaa0abcfa2932f992)) +* **router:** rename setSignalProvider callback detail to requestParam ([070c0f6](https://github.com/AliMD/alwatr/commit/070c0f6c5e4d6994e9af19dca515acc4f7ad4c5a)) +* **router:** trigger click signal name ([b4a9477](https://github.com/AliMD/alwatr/commit/b4a9477464cb05bb8fa227014de5e8af5b8dd600)) +* **signal:** fix dispatchSignal value parameters ([4d34cfb](https://github.com/AliMD/alwatr/commit/4d34cfbb5281d5ce4a4f06ddaaf72218dde80cdd)) +* **tsconfig:** add router ([a107e08](https://github.com/AliMD/alwatr/commit/a107e0872d59484ec208640b678e65212add53f0)) +* **util:** remove package ([b337d9a](https://github.com/AliMD/alwatr/commit/b337d9a97c8f73c2a87e722b23a50718321d1648)) ### Features -* **fetch:** add getData ([4a627c4](https://github.com/AliMD/One/commit/4a627c43d2ad07acb340f058f02d41ce57288405)) -* **fetch:** add postData and fetchJson ([b0262b8](https://github.com/AliMD/One/commit/b0262b83b5b7d8b7c376dce68aae3e16bd8e2610)) -* **fetch:** base fetch api ([925cdab](https://github.com/AliMD/One/commit/925cdab8700ffb801e1d836ffc5d3245b66815cf)) -* **fetch:** FetchOptions type ([dd2d141](https://github.com/AliMD/One/commit/dd2d1418d090387e1afa8277f78ae88ace17fd17)) -* **fetch:** new enhanced fetch package ([7e90472](https://github.com/AliMD/One/commit/7e904720c983372317358ce107f6ad0f79c65647)) -* **router:** _updateBrowserHistory ([8933a97](https://github.com/AliMD/One/commit/8933a97cde277708356fc123c7493774cf0b00ec)) -* **router:** base type ([f76d34b](https://github.com/AliMD/One/commit/f76d34b65fbfb9680662dd994136d90be99d496c)) -* **router:** first route request ([e0ad1d4](https://github.com/AliMD/One/commit/e0ad1d403f0023e2df44cb8b7a3a5710fcfbe877)) -* **router:** impeliment click trigger ([39f5f07](https://github.com/AliMD/One/commit/39f5f075f48ae4323ccca57467dde04ce8c9c3be)) -* **router:** impeliment popstate trigger ([1613131](https://github.com/AliMD/One/commit/16131312e4bc083ca3d6cf4c1458a93962946ccf)) -* **router:** initialRouter with trigers options ([802405f](https://github.com/AliMD/One/commit/802405fb17846be9fe51a41122c871b5aca9cf6b)) -* **router:** joinParameterList, splitParameterString ([9a4232b](https://github.com/AliMD/One/commit/9a4232b942f36a06cd3278e1a339639c9bcc82fa)) -* **router:** make new package for routing base on sognals ([39c9ae8](https://github.com/AliMD/One/commit/39c9ae8cf2d8288cfdefce0826f5fe89b2d7d550)) -* **router:** makeRouteObject ([6e0e5dc](https://github.com/AliMD/One/commit/6e0e5dc6fa10a6c02b1aeb198355040de6e235d2)) -* **router:** parseValue all sections and params value ([9af4079](https://github.com/AliMD/One/commit/9af4079f03dc2b656694f962701fcf75da23fa99)) -* **router:** requestRouteHref ([9341f3f](https://github.com/AliMD/One/commit/9341f3ff444bcdf26fd31f5eca71912dd70b7167)) -* **router:** route base types ([769e863](https://github.com/AliMD/One/commit/769e863b3a1569a01b320390b007bccaa80c3458)) -* **router:** routeSignalProvider ([ad187e7](https://github.com/AliMD/One/commit/ad187e706b6d62abd0668cf9bc7b64c49acab071)) -* **signal:** add contributors ([64287cd](https://github.com/AliMD/One/commit/64287cd8cea95665a6ed298177df60dadda7642b)) -* **signal:** improve signal provider by dispatch return content ([80c2b27](https://github.com/AliMD/One/commit/80c2b275bcc0521327400c5902f512c778f5eb3f)) -* **signal:** improve signal provider by dispatch return content ([188f295](https://github.com/AliMD/One/commit/188f2955e1663b318971e0d495bdd303a42bab56)) +* **fetch:** add getData ([4a627c4](https://github.com/AliMD/alwatr/commit/4a627c43d2ad07acb340f058f02d41ce57288405)) +* **fetch:** add postData and fetchJson ([b0262b8](https://github.com/AliMD/alwatr/commit/b0262b83b5b7d8b7c376dce68aae3e16bd8e2610)) +* **fetch:** base fetch api ([925cdab](https://github.com/AliMD/alwatr/commit/925cdab8700ffb801e1d836ffc5d3245b66815cf)) +* **fetch:** FetchOptions type ([dd2d141](https://github.com/AliMD/alwatr/commit/dd2d1418d090387e1afa8277f78ae88ace17fd17)) +* **fetch:** new enhanced fetch package ([7e90472](https://github.com/AliMD/alwatr/commit/7e904720c983372317358ce107f6ad0f79c65647)) +* **router:** _updateBrowserHistory ([8933a97](https://github.com/AliMD/alwatr/commit/8933a97cde277708356fc123c7493774cf0b00ec)) +* **router:** base type ([f76d34b](https://github.com/AliMD/alwatr/commit/f76d34b65fbfb9680662dd994136d90be99d496c)) +* **router:** first route request ([e0ad1d4](https://github.com/AliMD/alwatr/commit/e0ad1d403f0023e2df44cb8b7a3a5710fcfbe877)) +* **router:** impeliment click trigger ([39f5f07](https://github.com/AliMD/alwatr/commit/39f5f075f48ae4323ccca57467dde04ce8c9c3be)) +* **router:** impeliment popstate trigger ([1613131](https://github.com/AliMD/alwatr/commit/16131312e4bc083ca3d6cf4c1458a93962946ccf)) +* **router:** initialRouter with trigers options ([802405f](https://github.com/AliMD/alwatr/commit/802405fb17846be9fe51a41122c871b5aca9cf6b)) +* **router:** joinParameterList, splitParameterString ([9a4232b](https://github.com/AliMD/alwatr/commit/9a4232b942f36a06cd3278e1a339639c9bcc82fa)) +* **router:** make new package for routing base on sognals ([39c9ae8](https://github.com/AliMD/alwatr/commit/39c9ae8cf2d8288cfdefce0826f5fe89b2d7d550)) +* **router:** makeRouteObject ([6e0e5dc](https://github.com/AliMD/alwatr/commit/6e0e5dc6fa10a6c02b1aeb198355040de6e235d2)) +* **router:** parseValue all sections and params value ([9af4079](https://github.com/AliMD/alwatr/commit/9af4079f03dc2b656694f962701fcf75da23fa99)) +* **router:** requestRouteHref ([9341f3f](https://github.com/AliMD/alwatr/commit/9341f3ff444bcdf26fd31f5eca71912dd70b7167)) +* **router:** route base types ([769e863](https://github.com/AliMD/alwatr/commit/769e863b3a1569a01b320390b007bccaa80c3458)) +* **router:** routeSignalProvider ([ad187e7](https://github.com/AliMD/alwatr/commit/ad187e706b6d62abd0668cf9bc7b64c49acab071)) +* **signal:** add contributors ([64287cd](https://github.com/AliMD/alwatr/commit/64287cd8cea95665a6ed298177df60dadda7642b)) +* **signal:** improve signal provider by dispatch return content ([80c2b27](https://github.com/AliMD/alwatr/commit/80c2b275bcc0521327400c5902f512c778f5eb3f)) +* **signal:** improve signal provider by dispatch return content ([188f295](https://github.com/AliMD/alwatr/commit/188f2955e1663b318971e0d495bdd303a42bab56)) -## [0.1.2](https://github.com/AliMD/One/compare/v0.1.1...v0.1.2) (2022-03-03) +## [0.1.2](https://github.com/AliMD/alwatr/compare/v0.1.1...v0.1.2) (2022-03-03) -**Note:** Version bump only for package vatr +**Note:** Version bump only for package alwatr -## [0.1.1](https://github.com/AliMD/One/compare/v0.1.0...v0.1.1) (2022-03-03) +## [0.1.1](https://github.com/AliMD/alwatr/compare/v0.1.0...v0.1.1) (2022-03-03) ### Bug Fixes -* **packages:** add publish config to public ([9cb3710](https://github.com/AliMD/One/commit/9cb37106b5a35d24d5195ff54232e5769ccc034e)) +* **packages:** add publish config to public ([9cb3710](https://github.com/AliMD/alwatr/commit/9cb37106b5a35d24d5195ff54232e5769ccc034e)) # 0.1.0 (2022-03-02) ### Bug Fixes -* add lint to scripts ([18ef613](https://github.com/AliMD/One/commit/18ef613bf6dfe3bfa108f801ed9ab522efa16d9b)) -* add type module ([2649798](https://github.com/AliMD/One/commit/2649798c752138742cbdd14ee78768daa26f5b5a)) -* **bug:** fix ts list includes ([eba9b36](https://github.com/AliMD/One/commit/eba9b369ac3cc4f7e01933f304c5a11bcf8608a9)) -* **bug:** rootDir `src` to `.` ([4ad87ee](https://github.com/AliMD/One/commit/4ad87ee4a84b80afe563db5d42671ec9624ffce3)) -* change all [@one](https://github.com/one) to [@vatr](https://github.com/vatr) ([e0573bf](https://github.com/AliMD/One/commit/e0573bf8b55c9e25bad3f7b407cc2c3d509f36d3)) -* fix import module ([38dff29](https://github.com/AliMD/One/commit/38dff29a99e21f75f35be31bc11fb84e1f9d4a55)) -* fix port string to number ([6f5f133](https://github.com/AliMD/One/commit/6f5f1332f9851f976c83148ea2e113001d1526f7)) -* **logger:** fix debug scope ([be62f14](https://github.com/AliMD/One/commit/be62f142cbe3fe4d328e3fd9941ea7c2d640a23f)) -* **logger:** fix logger debug scope ([e734d21](https://github.com/AliMD/One/commit/e734d218db888ecec33a03dc805b98dd75543efd)) -* remove `src` and move all content to `root` ([3323322](https://github.com/AliMD/One/commit/33233220ed576f30249aa1197105219b62c65945)) -* remove `watch` scripts ([4e281b0](https://github.com/AliMD/One/commit/4e281b030693c0a828f78c5e77d84e851a2dd242)) -* remove license ([86a1100](https://github.com/AliMD/One/commit/86a11003026fb39321fe0a432974cc2f99c5d4b1)) -* remove serve script ([48bef31](https://github.com/AliMD/One/commit/48bef319cbb4e9838039dbffa5671af67566ec3f)) -* remove test package ([ac58dd8](https://github.com/AliMD/One/commit/ac58dd89ab5bdd87b40c24d16acef09e8aa1fdf7)) -* **signal:** VatrRequestSignals global type ([228e333](https://github.com/AliMD/One/commit/228e3333326b23df51e7834872daf1349826bf09)) -* tsconfig issues ([159adeb](https://github.com/AliMD/One/commit/159adeb72de4626dc16f6657765605b0a2ddccb1)) +* add lint to scripts ([18ef613](https://github.com/AliMD/alwatr/commit/18ef613bf6dfe3bfa108f801ed9ab522efa16d9b)) +* add type module ([2649798](https://github.com/AliMD/alwatr/commit/2649798c752138742cbdd14ee78768daa26f5b5a)) +* **bug:** fix ts list includes ([eba9b36](https://github.com/AliMD/alwatr/commit/eba9b369ac3cc4f7e01933f304c5a11bcf8608a9)) +* **bug:** rootDir `src` to `.` ([4ad87ee](https://github.com/AliMD/alwatr/commit/4ad87ee4a84b80afe563db5d42671ec9624ffce3)) +* change all [@one](https://github.com/one) to [@alwatr](https://github.com/alwatr) ([e0573bf](https://github.com/AliMD/alwatr/commit/e0573bf8b55c9e25bad3f7b407cc2c3d509f36d3)) +* fix import module ([38dff29](https://github.com/AliMD/alwatr/commit/38dff29a99e21f75f35be31bc11fb84e1f9d4a55)) +* fix port string to number ([6f5f133](https://github.com/AliMD/alwatr/commit/6f5f1332f9851f976c83148ea2e113001d1526f7)) +* **logger:** fix debug scope ([be62f14](https://github.com/AliMD/alwatr/commit/be62f142cbe3fe4d328e3fd9941ea7c2d640a23f)) +* **logger:** fix logger debug scope ([e734d21](https://github.com/AliMD/alwatr/commit/e734d218db888ecec33a03dc805b98dd75543efd)) +* remove `src` and move all content to `root` ([3323322](https://github.com/AliMD/alwatr/commit/33233220ed576f30249aa1197105219b62c65945)) +* remove `watch` scripts ([4e281b0](https://github.com/AliMD/alwatr/commit/4e281b030693c0a828f78c5e77d84e851a2dd242)) +* remove license ([86a1100](https://github.com/AliMD/alwatr/commit/86a11003026fb39321fe0a432974cc2f99c5d4b1)) +* remove serve script ([48bef31](https://github.com/AliMD/alwatr/commit/48bef319cbb4e9838039dbffa5671af67566ec3f)) +* remove test package ([ac58dd8](https://github.com/AliMD/alwatr/commit/ac58dd89ab5bdd87b40c24d16acef09e8aa1fdf7)) +* **signal:** AlwatrRequestSignals global type ([228e333](https://github.com/AliMD/alwatr/commit/228e3333326b23df51e7834872daf1349826bf09)) +* tsconfig issues ([159adeb](https://github.com/AliMD/alwatr/commit/159adeb72de4626dc16f6657765605b0a2ddccb1)) ### Features -* add .editorconfig file ([d05f1d3](https://github.com/AliMD/One/commit/d05f1d3f9f1e81316d52831c8b2f776728fc967c)) -* add eslint configuration ([1360f31](https://github.com/AliMD/One/commit/1360f317c6b1031640e410549499f1510d50e862)) -* add ts-lint.json ([5c592d8](https://github.com/AliMD/One/commit/5c592d8e4643d2e9dc85fd0582eec054e0e02463)) -* build demo ([e50b310](https://github.com/AliMD/One/commit/e50b3106f428a2a11cc0d960970017d564caa017)) -* build index ([93b604f](https://github.com/AliMD/One/commit/93b604f44d43eedec5df1dd47ad84b96a99ed9b7)) -* demo html ([de43204](https://github.com/AliMD/One/commit/de432043c1b46f2c8f0d9c4f46580b31f3eee066)) -* **demo:** add error and force sample ([0aa2edd](https://github.com/AliMD/One/commit/0aa2edd896b417ea79a249f3332ad629e80a17fa)) -* **demo:** add vatr logger demo ([f759a06](https://github.com/AliMD/One/commit/f759a06f65545d3589a136f2b9a553dfdb1f2af2)) -* **demo:** vatr logger demo ([302c6f4](https://github.com/AliMD/One/commit/302c6f46fcc00796e6c030c6fe98a6c2b9f21d04)) -* **logger:** debug scope ([6e4190d](https://github.com/AliMD/One/commit/6e4190dc9dafc28e3a7a481aa43622a23527993c)) -* **logger:** debug scope ([67dbde0](https://github.com/AliMD/One/commit/67dbde00d925c2d78ae069439abe2a8a55d188b4)) -* **logger:** debug scope logger package ([1a4baeb](https://github.com/AliMD/One/commit/1a4baeb7a253ba66563dbcf06079242dabb9f246)) -* **logger:** vatr logger package ([711268e](https://github.com/AliMD/One/commit/711268e17dea8ada9c901ef1e9d605b3212abd97)) -* **logger:** vatr meta structure ([feade73](https://github.com/AliMD/One/commit/feade735a6f141db77b81d7791d8872d45c8bf7e)) -* **scripts:** add watch commands ([af66f88](https://github.com/AliMD/One/commit/af66f8848065750a414eda55c69f505b24c2da32)) -* **server:** build index file ([930bf86](https://github.com/AliMD/One/commit/930bf86c0158929c14ebdefbaeeb6ded80be4450)) -* **server:** install and config web dev server ([2b42610](https://github.com/AliMD/One/commit/2b4261050b855bddd2f594868993305d37086be8)) -* **signal:** addSignalListener ([e7c5742](https://github.com/AliMD/One/commit/e7c57427ef11e2624eb9a52a166720b1a3c5f66a)) -* **signal:** getSignalObject ([b38954c](https://github.com/AliMD/One/commit/b38954cf4ae1c24eaaa79ecf513995a4678814ee)) -* **signal:** impeliment addSignalProvider, waitForSignal, hasSignalDispatchedBefore, expireSignal ([e0b4d78](https://github.com/AliMD/One/commit/e0b4d7831764d4454591f5105c5512e1657a63e5)) -* **signal:** impeliment dispatchSignal ([cb2dfbe](https://github.com/AliMD/One/commit/cb2dfbe23ea751cba93cb1f6516cd2bfa2ecb18e)) -* **signal:** ListenerObject, SignalObject types ([36d8a33](https://github.com/AliMD/One/commit/36d8a336760bba3808cfd26a28e4d24a31c95f8f)) -* **signal:** make new package for manage signals ([5bf82b3](https://github.com/AliMD/One/commit/5bf82b3f05abc89102634e9b864d81b5b5af527e)) -* **signal:** register to vatr meta ([9c850e8](https://github.com/AliMD/One/commit/9c850e8df787aa44d289929dc65439e921982dce)) -* **signal:** removeSignalListener ([0088a52](https://github.com/AliMD/One/commit/0088a5269ccce8b50a50e444695c81654fda70ff)) -* **signal:** requestSignal ([111ab5a](https://github.com/AliMD/One/commit/111ab5a1436bc380f5121ef8c130da7010258d90)) -* **svg-icon:** init svg-icon package (ionicons) ([#14](https://github.com/AliMD/One/issues/14)) ([5b3a8f6](https://github.com/AliMD/One/commit/5b3a8f67f5676e0a2139cfa30b60666190c991cf)) +* add .editorconfig file ([d05f1d3](https://github.com/AliMD/alwatr/commit/d05f1d3f9f1e81316d52831c8b2f776728fc967c)) +* add eslint configuration ([1360f31](https://github.com/AliMD/alwatr/commit/1360f317c6b1031640e410549499f1510d50e862)) +* add ts-lint.json ([5c592d8](https://github.com/AliMD/alwatr/commit/5c592d8e4643d2e9dc85fd0582eec054e0e02463)) +* build demo ([e50b310](https://github.com/AliMD/alwatr/commit/e50b3106f428a2a11cc0d960970017d564caa017)) +* build index ([93b604f](https://github.com/AliMD/alwatr/commit/93b604f44d43eedec5df1dd47ad84b96a99ed9b7)) +* demo html ([de43204](https://github.com/AliMD/alwatr/commit/de432043c1b46f2c8f0d9c4f46580b31f3eee066)) +* **demo:** add error and force sample ([0aa2edd](https://github.com/AliMD/alwatr/commit/0aa2edd896b417ea79a249f3332ad629e80a17fa)) +* **demo:** add alwatr logger demo ([f759a06](https://github.com/AliMD/alwatr/commit/f759a06f65545d3589a136f2b9a553dfdb1f2af2)) +* **demo:** alwatr logger demo ([302c6f4](https://github.com/AliMD/alwatr/commit/302c6f46fcc00796e6c030c6fe98a6c2b9f21d04)) +* **logger:** debug scope ([6e4190d](https://github.com/AliMD/alwatr/commit/6e4190dc9dafc28e3a7a481aa43622a23527993c)) +* **logger:** debug scope ([67dbde0](https://github.com/AliMD/alwatr/commit/67dbde00d925c2d78ae069439abe2a8a55d188b4)) +* **logger:** debug scope logger package ([1a4baeb](https://github.com/AliMD/alwatr/commit/1a4baeb7a253ba66563dbcf06079242dabb9f246)) +* **logger:** alwatr logger package ([711268e](https://github.com/AliMD/alwatr/commit/711268e17dea8ada9c901ef1e9d605b3212abd97)) +* **logger:** alwatr meta structure ([feade73](https://github.com/AliMD/alwatr/commit/feade735a6f141db77b81d7791d8872d45c8bf7e)) +* **scripts:** add watch commands ([af66f88](https://github.com/AliMD/alwatr/commit/af66f8848065750a414eda55c69f505b24c2da32)) +* **server:** build index file ([930bf86](https://github.com/AliMD/alwatr/commit/930bf86c0158929c14ebdefbaeeb6ded80be4450)) +* **server:** install and config web dev server ([2b42610](https://github.com/AliMD/alwatr/commit/2b4261050b855bddd2f594868993305d37086be8)) +* **signal:** addSignalListener ([e7c5742](https://github.com/AliMD/alwatr/commit/e7c57427ef11e2624eb9a52a166720b1a3c5f66a)) +* **signal:** getSignalObject ([b38954c](https://github.com/AliMD/alwatr/commit/b38954cf4ae1c24eaaa79ecf513995a4678814ee)) +* **signal:** impeliment addSignalProvider, waitForSignal, hasSignalDispatchedBefore, expireSignal ([e0b4d78](https://github.com/AliMD/alwatr/commit/e0b4d7831764d4454591f5105c5512e1657a63e5)) +* **signal:** impeliment dispatchSignal ([cb2dfbe](https://github.com/AliMD/alwatr/commit/cb2dfbe23ea751cba93cb1f6516cd2bfa2ecb18e)) +* **signal:** ListenerObject, SignalObject types ([36d8a33](https://github.com/AliMD/alwatr/commit/36d8a336760bba3808cfd26a28e4d24a31c95f8f)) +* **signal:** make new package for manage signals ([5bf82b3](https://github.com/AliMD/alwatr/commit/5bf82b3f05abc89102634e9b864d81b5b5af527e)) +* **signal:** register to alwatr meta ([9c850e8](https://github.com/AliMD/alwatr/commit/9c850e8df787aa44d289929dc65439e921982dce)) +* **signal:** removeSignalListener ([0088a52](https://github.com/AliMD/alwatr/commit/0088a5269ccce8b50a50e444695c81654fda70ff)) +* **signal:** requestSignal ([111ab5a](https://github.com/AliMD/alwatr/commit/111ab5a1436bc380f5121ef8c130da7010258d90)) +* **svg-icon:** init svg-icon package (ionicons) ([#14](https://github.com/AliMD/alwatr/issues/14)) ([5b3a8f6](https://github.com/AliMD/alwatr/commit/5b3a8f67f5676e0a2139cfa30b60666190c991cf)) diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md index df750c26b..b86c35808 100644 --- a/CODE_OF_CONDUCT.md +++ b/CODE_OF_CONDUCT.md @@ -1,11 +1,11 @@ # Contributor Code of Conduct -As contributors and maintainers of the AlVatr projects, we pledge to respect everyone who contributes by posting issues, updating documentation, submitting pull requests, providing feedback in comments, and any other activities. +As contributors and maintainers of the Alwatr projects, we pledge to respect everyone who contributes by posting issues, updating documentation, submitting pull requests, providing feedback in comments, and any other activities. -Communication through any of AlVatr channels (GitHub, Telegram, Twitter, etc.) must be constructive and never resort to personal attacks, trolling, public or private harassment, insults, or other unprofessional conduct. +Communication through any of Alwatr channels (GitHub, Telegram, Twitter, etc.) must be constructive and never resort to personal attacks, trolling, public or private harassment, insults, or other unprofessional conduct. -We promise to extend courtesy and respect to everyone involved in this project regardless of gender, gender identity, sexual orientation, disability, age, race, ethnicity, religion, or level of experience. We expect anyone contributing to the AlVatr projects to do the same. +We promise to extend courtesy and respect to everyone involved in this project regardless of gender, gender identity, sexual orientation, disability, age, race, ethnicity, religion, or level of experience. We expect anyone contributing to the Alwatr projects to do the same. -If any member of the community violates this code of conduct, the maintainers of the AlVatr projects may take action, removing issues, comments, and PRs or blocking accounts as deemed appropriate. +If any member of the community violates this code of conduct, the maintainers of the Alwatr projects may take action, removing issues, comments, and PRs or blocking accounts as deemed appropriate. If you are subject to or witness unacceptable behavior, or have any other concerns, please email us at [ali.mihandoost@gmail.com](mailto:ali.mihandoost@gmail.com). diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 5f5247527..ee7cf3c9e 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,11 +1,11 @@ -# Contributing to AlVatr projects +# Contributing to Alwatr projects -We would love for you to contribute to AlVatr projects and help make it even better than it is today! +We would love for you to contribute to Alwatr projects and help make it even better than it is today! As a contributor, here are the guidelines we would like you to follow: ## Code of Conduct -Help us keep AlVatr projects open and inclusive. +Help us keep Alwatr projects open and inclusive. Please read and follow our [Code of Conduct](./CODE_OF_CONDUCT.md). ## Found a Bug? diff --git a/README.md b/README.md index 97e7e3b15..ce2d278d2 100644 --- a/README.md +++ b/README.md @@ -1 +1 @@ -# The Vatr Library (Alvatr Library) +# The Alwatr Library diff --git a/demo/CHANGELOG.md b/demo/CHANGELOG.md index 4bfd1c312..0bfac28b8 100644 --- a/demo/CHANGELOG.md +++ b/demo/CHANGELOG.md @@ -3,64 +3,64 @@ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. -# [0.5.0](https://github.com/AliMD/One/compare/v0.4.0...v0.5.0) (2022-03-11) +# [0.5.0](https://github.com/AliMD/alwatr/compare/v0.4.0...v0.5.0) (2022-03-11) -**Note:** Version bump only for package @vatr/demo +**Note:** Version bump only for package @alwatr/demo -# [0.4.0](https://github.com/AliMD/One/compare/v0.3.0...v0.4.0) (2022-03-11) +# [0.4.0](https://github.com/AliMD/alwatr/compare/v0.3.0...v0.4.0) (2022-03-11) ### Features -* **logger:** add logProperty, logMethodFull ([8b0317d](https://github.com/AliMD/One/commit/8b0317db88ed73604a27935a3a30cd5c31cb0804)) -* **logger:** complete refactor the logger with new API and fix show correct line number ([7efe8cf](https://github.com/AliMD/One/commit/7efe8cf0f566e148406f38fdd60fa3d747c9bc51)) +* **logger:** add logProperty, logMethodFull ([8b0317d](https://github.com/AliMD/alwatr/commit/8b0317db88ed73604a27935a3a30cd5c31cb0804)) +* **logger:** complete refactor the logger with new API and fix show correct line number ([7efe8cf](https://github.com/AliMD/alwatr/commit/7efe8cf0f566e148406f38fdd60fa3d747c9bc51)) -# [0.3.0](https://github.com/AliMD/One/compare/v0.2.1...v0.3.0) (2022-03-06) +# [0.3.0](https://github.com/AliMD/alwatr/compare/v0.2.1...v0.3.0) (2022-03-06) -**Note:** Version bump only for package @vatr/demo +**Note:** Version bump only for package @alwatr/demo -## [0.2.1](https://github.com/AliMD/One/compare/v0.2.0...v0.2.1) (2022-03-05) +## [0.2.1](https://github.com/AliMD/alwatr/compare/v0.2.0...v0.2.1) (2022-03-05) -**Note:** Version bump only for package @vatr/demo +**Note:** Version bump only for package @alwatr/demo -# [0.2.0](https://github.com/AliMD/One/compare/v0.1.2...v0.2.0) (2022-03-05) +# [0.2.0](https://github.com/AliMD/alwatr/compare/v0.1.2...v0.2.0) (2022-03-05) ### Bug Fixes -* **util:** remove package ([b337d9a](https://github.com/AliMD/One/commit/b337d9a97c8f73c2a87e722b23a50718321d1648)) +* **util:** remove package ([b337d9a](https://github.com/AliMD/alwatr/commit/b337d9a97c8f73c2a87e722b23a50718321d1648)) -## [0.1.2](https://github.com/AliMD/One/compare/v0.1.1...v0.1.2) (2022-03-03) +## [0.1.2](https://github.com/AliMD/alwatr/compare/v0.1.1...v0.1.2) (2022-03-03) -**Note:** Version bump only for package @vatr/demo +**Note:** Version bump only for package @alwatr/demo -## [0.1.1](https://github.com/AliMD/One/compare/v0.1.0...v0.1.1) (2022-03-03) +## [0.1.1](https://github.com/AliMD/alwatr/compare/v0.1.0...v0.1.1) (2022-03-03) -**Note:** Version bump only for package @vatr/demo +**Note:** Version bump only for package @alwatr/demo @@ -71,19 +71,19 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline ### Bug Fixes -* add type module ([2649798](https://github.com/AliMD/One/commit/2649798c752138742cbdd14ee78768daa26f5b5a)) -* **bug:** rootDir `src` to `.` ([4ad87ee](https://github.com/AliMD/One/commit/4ad87ee4a84b80afe563db5d42671ec9624ffce3)) -* change all [@one](https://github.com/one) to [@vatr](https://github.com/vatr) ([e0573bf](https://github.com/AliMD/One/commit/e0573bf8b55c9e25bad3f7b407cc2c3d509f36d3)) -* fix import module ([38dff29](https://github.com/AliMD/One/commit/38dff29a99e21f75f35be31bc11fb84e1f9d4a55)) -* remove `src` and move all content to `root` ([3323322](https://github.com/AliMD/One/commit/33233220ed576f30249aa1197105219b62c65945)) +* add type module ([2649798](https://github.com/AliMD/alwatr/commit/2649798c752138742cbdd14ee78768daa26f5b5a)) +* **bug:** rootDir `src` to `.` ([4ad87ee](https://github.com/AliMD/alwatr/commit/4ad87ee4a84b80afe563db5d42671ec9624ffce3)) +* change all [@one](https://github.com/one) to [@alwatr](https://github.com/alwatr) ([e0573bf](https://github.com/AliMD/alwatr/commit/e0573bf8b55c9e25bad3f7b407cc2c3d509f36d3)) +* fix import module ([38dff29](https://github.com/AliMD/alwatr/commit/38dff29a99e21f75f35be31bc11fb84e1f9d4a55)) +* remove `src` and move all content to `root` ([3323322](https://github.com/AliMD/alwatr/commit/33233220ed576f30249aa1197105219b62c65945)) ### Features -* build demo ([e50b310](https://github.com/AliMD/One/commit/e50b3106f428a2a11cc0d960970017d564caa017)) -* build index ([93b604f](https://github.com/AliMD/One/commit/93b604f44d43eedec5df1dd47ad84b96a99ed9b7)) -* demo html ([de43204](https://github.com/AliMD/One/commit/de432043c1b46f2c8f0d9c4f46580b31f3eee066)) -* **demo:** add error and force sample ([0aa2edd](https://github.com/AliMD/One/commit/0aa2edd896b417ea79a249f3332ad629e80a17fa)) -* **demo:** add vatr logger demo ([f759a06](https://github.com/AliMD/One/commit/f759a06f65545d3589a136f2b9a553dfdb1f2af2)) -* **demo:** vatr logger demo ([302c6f4](https://github.com/AliMD/One/commit/302c6f46fcc00796e6c030c6fe98a6c2b9f21d04)) -* **svg-icon:** init svg-icon package (ionicons) ([#14](https://github.com/AliMD/One/issues/14)) ([5b3a8f6](https://github.com/AliMD/One/commit/5b3a8f67f5676e0a2139cfa30b60666190c991cf)) +* build demo ([e50b310](https://github.com/AliMD/alwatr/commit/e50b3106f428a2a11cc0d960970017d564caa017)) +* build index ([93b604f](https://github.com/AliMD/alwatr/commit/93b604f44d43eedec5df1dd47ad84b96a99ed9b7)) +* demo html ([de43204](https://github.com/AliMD/alwatr/commit/de432043c1b46f2c8f0d9c4f46580b31f3eee066)) +* **demo:** add error and force sample ([0aa2edd](https://github.com/AliMD/alwatr/commit/0aa2edd896b417ea79a249f3332ad629e80a17fa)) +* **demo:** add alwatr logger demo ([f759a06](https://github.com/AliMD/alwatr/commit/f759a06f65545d3589a136f2b9a553dfdb1f2af2)) +* **demo:** alwatr logger demo ([302c6f4](https://github.com/AliMD/alwatr/commit/302c6f46fcc00796e6c030c6fe98a6c2b9f21d04)) +* **svg-icon:** init svg-icon package (ionicons) ([#14](https://github.com/AliMD/alwatr/issues/14)) ([5b3a8f6](https://github.com/AliMD/alwatr/commit/5b3a8f67f5676e0a2139cfa30b60666190c991cf)) diff --git a/demo/logger/index.ts b/demo/logger/index.ts index 62ea538d0..7778c8f11 100644 --- a/demo/logger/index.ts +++ b/demo/logger/index.ts @@ -1,4 +1,4 @@ -import {createLogger} from '@vatr/logger'; +import {createLogger} from '@alwatr/logger'; const logger = createLogger('logger/demo', 'green'); diff --git a/demo/package.json b/demo/package.json index 79607d6b3..29e603633 100644 --- a/demo/package.json +++ b/demo/package.json @@ -1,31 +1,15 @@ { - "name": "@vatr/demo", + "name": "@alwatr/demo", "version": "0.5.0", - "description": "@vatr packages demo", "main": "index.js", - "author": "@vatr community", + "author": "S. Ali Mihandoost (https://ali.mihandoost.com)", "type": "module", "private": "true", - "repository": { - "type": "git", - "url": "https://github.com/AliMD/One/tree/next/demo" - }, - "files": [ - "*.js", - "*.js.map", - "*.d.ts", - "*.d.ts.map", - "*.md", - "LICENSE" - ], - "publishConfig": { - "access": "public" - }, "contributors": [ "MohammadMahdi Zamanian " ], "dependencies": { - "@vatr/logger": "^0.5.0", + "@alwatr/logger": "^0.5.0", "lit": "^2.1.3", "tslib": "^2.2.0" } diff --git a/package.json b/package.json index 7af313f59..034e634bc 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { - "name": "vatr", - "description": "The Vatr Library", - "repository": "https://github.com/AliMD/One", + "name": "alwatr", + "description": "The Alwatr Library", + "repository": "https://github.com/AliMD/alwatr/", "author": "S. Ali Mihandoost (https://ali.mihandoost.com)", "license": "MIT", "private": true, diff --git a/package/fetch/CHANGELOG.md b/package/fetch/CHANGELOG.md index 391bc0cd8..8862c5471 100644 --- a/package/fetch/CHANGELOG.md +++ b/package/fetch/CHANGELOG.md @@ -3,53 +3,34 @@ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. -# [0.5.0](https://github.com/AliMD/vatr/compare/v0.4.0...v0.5.0) (2022-03-11) +# [0.5.0](https://github.com/AliMD/alwatr/compare/v0.4.0...v0.5.0) (2022-03-11) -**Note:** Version bump only for package @vatr/fetch - - - - - -# [0.4.0](https://github.com/AliMD/vatr/compare/v0.3.0...v0.4.0) (2022-03-11) +**Note:** Version bump only for package @alwatr/fetch +# [0.4.0](https://github.com/AliMD/alwatr/compare/v0.3.0...v0.4.0) (2022-03-11) ### Bug Fixes -* **fetch:** build issue [#73](https://github.com/AliMD/vatr/issues/73) ([fb74463](https://github.com/AliMD/vatr/commit/fb74463d367393706d16e482488a565bdfef70a1)) - - - - - -# [0.3.0](https://github.com/AliMD/vatr/compare/v0.2.1...v0.3.0) (2022-03-06) +* **fetch:** build issue [#73](https://github.com/AliMD/alwatr/issues/73) ([fb74463](https://github.com/AliMD/alwatr/commit/fb74463d367393706d16e482488a565bdfef70a1)) -**Note:** Version bump only for package @vatr/fetch +# [0.3.0](https://github.com/AliMD/alwatr/compare/v0.2.1...v0.3.0) (2022-03-06) +**Note:** Version bump only for package @alwatr/fetch +## [0.2.1](https://github.com/AliMD/alwatr/compare/v0.2.0...v0.2.1) (2022-03-05) +**Note:** Version bump only for package @alwatr/fetch - -## [0.2.1](https://github.com/AliMD/vatr/compare/v0.2.0...v0.2.1) (2022-03-05) - -**Note:** Version bump only for package @vatr/fetch - - - - - -# [0.2.0](https://github.com/AliMD/vatr/compare/v0.1.2...v0.2.0) (2022-03-05) - +# [0.2.0](https://github.com/AliMD/alwatr/compare/v0.1.2...v0.2.0) (2022-03-05) ### Bug Fixes -* **fetch:** error codes ([4e0be80](https://github.com/AliMD/vatr/commit/4e0be80786b6667035ae82750f2351bd2da4f341)) - +* **fetch:** error codes ([4e0be80](https://github.com/AliMD/alwatr/commit/4e0be80786b6667035ae82750f2351bd2da4f341)) ### Features -* **fetch:** add getData ([4a627c4](https://github.com/AliMD/vatr/commit/4a627c43d2ad07acb340f058f02d41ce57288405)) -* **fetch:** add postData and fetchJson ([b0262b8](https://github.com/AliMD/vatr/commit/b0262b83b5b7d8b7c376dce68aae3e16bd8e2610)) -* **fetch:** base fetch api ([925cdab](https://github.com/AliMD/vatr/commit/925cdab8700ffb801e1d836ffc5d3245b66815cf)) -* **fetch:** FetchOptions type ([dd2d141](https://github.com/AliMD/vatr/commit/dd2d1418d090387e1afa8277f78ae88ace17fd17)) -* **fetch:** new enhanced fetch package ([7e90472](https://github.com/AliMD/vatr/commit/7e904720c983372317358ce107f6ad0f79c65647)) +* **fetch:** add getData ([4a627c4](https://github.com/AliMD/alwatr/commit/4a627c43d2ad07acb340f058f02d41ce57288405)) +* **fetch:** add postData and fetchJson ([b0262b8](https://github.com/AliMD/alwatr/commit/b0262b83b5b7d8b7c376dce68aae3e16bd8e2610)) +* **fetch:** base fetch api ([925cdab](https://github.com/AliMD/alwatr/commit/925cdab8700ffb801e1d836ffc5d3245b66815cf)) +* **fetch:** FetchOptions type ([dd2d141](https://github.com/AliMD/alwatr/commit/dd2d1418d090387e1afa8277f78ae88ace17fd17)) +* **fetch:** new enhanced fetch package ([7e90472](https://github.com/AliMD/alwatr/commit/7e904720c983372317358ce107f6ad0f79c65647)) diff --git a/package/fetch/README.md b/package/fetch/README.md index f03495764..dd961bd17 100644 --- a/package/fetch/README.md +++ b/package/fetch/README.md @@ -1,4 +1,4 @@ -# @vatr/fetch +# @alwatr/fetch Enhanced fetch API with the timeout, helper methods, and types written in tiny TypeScript, ES module. @@ -14,7 +14,7 @@ Options have two other parameters: ## Example usage ```js -import {getJson} from 'https://esm.run/@vatr/fetch'; +import {getJson} from 'https://esm.run/@alwatr/fetch'; const productList = await getJson('/api/products', {limit: 10}, {timeout: 5_000}); ``` diff --git a/package/fetch/package.json b/package/fetch/package.json index 79c43a338..da4b97580 100644 --- a/package/fetch/package.json +++ b/package/fetch/package.json @@ -1,5 +1,5 @@ { - "name": "@vatr/fetch", + "name": "@alwatr/fetch", "version": "0.5.0", "description": "Enhanced fetch api with timeout, helper methods and types written in tiny TypeScript module.", "keywords": [ @@ -9,8 +9,7 @@ "timeout", "typescript", "esm", - "vatr", - "alvatr" + "alwatr" ], "main": "fetch.js", "type": "module", @@ -29,15 +28,15 @@ }, "repository": { "type": "git", - "url": "https://github.com/AliMD/vatr", + "url": "https://github.com/AliMD/alwatr", "directory": "package/fetch" }, - "homepage": "https://github.com/AliMD/vatr/tree/main/package/fetch#readme", + "homepage": "https://github.com/AliMD/alwatr/tree/main/package/fetch#readme", "bugs": { - "url": "https://github.com/AliMD/vatr/issues" + "url": "https://github.com/AliMD/alwatr/issues" }, "dependencies": { - "@vatr/logger": "^0.5.0", + "@alwatr/logger": "^0.5.0", "tslib": "^2.3.1" } } diff --git a/package/fetch/src/fetch.ts b/package/fetch/src/fetch.ts index 30d58d470..9a3dd9807 100644 --- a/package/fetch/src/fetch.ts +++ b/package/fetch/src/fetch.ts @@ -1,10 +1,10 @@ -import {createLogger, vatrRegisteredList} from '@vatr/logger'; +import {createLogger, alwatrRegisteredList} from '@alwatr/logger'; -const logger = createLogger('vatr/fetch'); +const logger = createLogger('alwatr/fetch'); -vatrRegisteredList.push({ - name: '@vatr/fetch', - version: '{{VATR_VERSION}}', +alwatrRegisteredList.push({ + name: '@alwatr/fetch', + version: '{{ALWATR_VERSION}}', }); declare global { diff --git a/package/i18n/CHANGELOG.md b/package/i18n/CHANGELOG.md index 04f9af4fe..7c717e8d3 100644 --- a/package/i18n/CHANGELOG.md +++ b/package/i18n/CHANGELOG.md @@ -3,31 +3,21 @@ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. -# [0.5.0](https://github.com/AliMD/vatr/compare/v0.4.0...v0.5.0) (2022-03-11) +# [0.5.0](https://github.com/AliMD/alwatr/compare/v0.4.0...v0.5.0) (2022-03-11) -**Note:** Version bump only for package @vatr/i18n - - - - - -# [0.4.0](https://github.com/AliMD/vatr/compare/v0.3.0...v0.4.0) (2022-03-11) +**Note:** Version bump only for package @alwatr/i18n +# [0.4.0](https://github.com/AliMD/alwatr/compare/v0.3.0...v0.4.0) (2022-03-11) ### Bug Fixes -* **i18n:** build issue [#75](https://github.com/AliMD/vatr/issues/75) ([fe7a108](https://github.com/AliMD/vatr/commit/fe7a108904176e63b8aa7e388d95ee8a90c6b71f)) - - - - - -# [0.3.0](https://github.com/AliMD/vatr/compare/v0.2.1...v0.3.0) (2022-03-06) +* **i18n:** build issue [#75](https://github.com/AliMD/alwatr/issues/75) ([fe7a108](https://github.com/AliMD/alwatr/commit/fe7a108904176e63b8aa7e388d95ee8a90c6b71f)) +# [0.3.0](https://github.com/AliMD/alwatr/compare/v0.2.1...v0.3.0) (2022-03-06) ### Features -* **i18n:** impeliment core methods ([6449bb4](https://github.com/AliMD/vatr/commit/6449bb42837335c2e2e5b4a75e98139528e2e7da)) -* **i18n:** impeliment initialI18n ([87da5e4](https://github.com/AliMD/vatr/commit/87da5e46943ba12a8067fcac06c1dcced1e6fb92)) -* **i18n:** localize method ([544edfd](https://github.com/AliMD/vatr/commit/544edfdd1bc52befab6afe4cbfb62ce1638aff2d)) -* **i18n:** start new package for i18n/l10n ([88a6c28](https://github.com/AliMD/vatr/commit/88a6c28ad038ed02ca45128378e669f6d9c6949d)) +* **i18n:** implement core methods ([6449bb4](https://github.com/AliMD/alwatr/commit/6449bb42837335c2e2e5b4a75e98139528e2e7da)) +* **i18n:** implement initialI18n ([87da5e4](https://github.com/AliMD/alwatr/commit/87da5e46943ba12a8067fcac06c1dcced1e6fb92)) +* **i18n:** localize method ([544edfd](https://github.com/AliMD/alwatr/commit/544edfdd1bc52befab6afe4cbfb62ce1638aff2d)) +* **i18n:** start new package for i18n/l10n ([88a6c28](https://github.com/AliMD/alwatr/commit/88a6c28ad038ed02ca45128378e669f6d9c6949d)) diff --git a/package/i18n/README.md b/package/i18n/README.md index 1b59606db..3f412ddcd 100644 --- a/package/i18n/README.md +++ b/package/i18n/README.md @@ -1,4 +1,4 @@ -# @vatr/fetch +# @alwatr/fetch Elegant powerful translation module (i18n/l10n) with dynamic json storage written in tiny TypeScript, ES module. @@ -7,14 +7,14 @@ Elegant powerful translation module (i18n/l10n) with dynamic json storage writte ### Initialize ```js -import {initialI18n} from 'https://esm.run/@vatr/i18n'; +import {initialI18n} from 'https://esm.run/@alwatr/i18n'; initialI18n(); ``` ### Localize in template string ```js -import {localize} from 'https://esm.run/@vatr/i18n'; +import {localize} from 'https://esm.run/@alwatr/i18n'; render() { return html` diff --git a/package/i18n/package.json b/package/i18n/package.json index 084edacb9..46f9f57c2 100644 --- a/package/i18n/package.json +++ b/package/i18n/package.json @@ -1,5 +1,5 @@ { - "name": "@vatr/i18n", + "name": "@alwatr/i18n", "version": "0.5.0", "description": "Elegant powerful translation module (i18n/l10n) with dynamic json storage written in tiny TypeScript, ES module.", "keywords": [ @@ -9,8 +9,7 @@ "localization", "typescript", "esm", - "vatr", - "alvatr" + "alwatr" ], "main": "i18n.js", "type": "module", @@ -29,17 +28,17 @@ }, "repository": { "type": "git", - "url": "https://github.com/AliMD/vatr", + "url": "https://github.com/AliMD/alwatr", "directory": "package/i18n" }, - "homepage": "https://github.com/AliMD/vatr/tree/main/package/i18n#readme", + "homepage": "https://github.com/AliMD/alwatr/tree/main/package/i18n#readme", "bugs": { - "url": "https://github.com/AliMD/vatr/issues" + "url": "https://github.com/AliMD/alwatr/issues" }, "dependencies": { - "@vatr/fetch": "^0.5.0", - "@vatr/logger": "^0.5.0", - "@vatr/signal": "^0.5.0", + "@alwatr/fetch": "^0.5.0", + "@alwatr/logger": "^0.5.0", + "@alwatr/signal": "^0.5.0", "tslib": "^2.3.1" } } diff --git a/package/i18n/src/core.ts b/package/i18n/src/core.ts index 1c41e8ab8..a98e795be 100644 --- a/package/i18n/src/core.ts +++ b/package/i18n/src/core.ts @@ -1,14 +1,14 @@ -import {createLogger, vatrRegisteredList} from '@vatr/logger'; -import {SignalInterface} from '@vatr/signal'; -import {getJson} from '@vatr/fetch'; +import {createLogger, alwatrRegisteredList} from '@alwatr/logger'; +import {SignalInterface} from '@alwatr/signal'; +import {getJson} from '@alwatr/fetch'; import type {I18nOptions, L10Resource} from './type'; -vatrRegisteredList.push({ - name: '@vatr/i18n', - version: '{{VATR_VERSION}}', +alwatrRegisteredList.push({ + name: '@alwatr/i18n', + version: '{{ALWATR_VERSION}}', }); -export const logger = createLogger('vatr/i18n'); +export const logger = createLogger('alwatr/i18n'); export const configuration: I18nOptions = { autoFetchResources: true, diff --git a/package/i18n/src/type.ts b/package/i18n/src/type.ts index 2308fac99..42f2933e5 100644 --- a/package/i18n/src/type.ts +++ b/package/i18n/src/type.ts @@ -1,9 +1,9 @@ declare global { - interface VatrSignals { + interface AlwatrSignals { 'local-change': Local; 'l10n-resource-change': L10Resource; } - interface VatrRequestSignals { + interface AlwatrRequestSignals { 'l10n-resource-change': Local; } } diff --git a/package/logger/CHANGELOG.md b/package/logger/CHANGELOG.md index 394de1c23..956738d3e 100644 --- a/package/logger/CHANGELOG.md +++ b/package/logger/CHANGELOG.md @@ -3,86 +3,58 @@ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. -# [0.5.0](https://github.com/AliMD/vatr/compare/v0.4.0...v0.5.0) (2022-03-11) - +# [0.5.0](https://github.com/AliMD/alwatr/compare/v0.4.0...v0.5.0) (2022-03-11) ### Performance Improvements -* **logger:** refactor making logger object ([bc38018](https://github.com/AliMD/vatr/commit/bc38018758540130df2f46c44521aea0a867bbe8)) - - - - - -# [0.4.0](https://github.com/AliMD/vatr/compare/v0.3.0...v0.4.0) (2022-03-11) +* **logger:** refactor making logger object ([bc38018](https://github.com/AliMD/alwatr/commit/bc38018758540130df2f46c44521aea0a867bbe8)) +# [0.4.0](https://github.com/AliMD/alwatr/compare/v0.3.0...v0.4.0) (2022-03-11) ### Bug Fixes -* **logger:** types missing ([712363d](https://github.com/AliMD/vatr/commit/712363d3cf77a712f8c801c4dc9d06d256dfc0e6)) - +* **logger:** types missing ([712363d](https://github.com/AliMD/alwatr/commit/712363d3cf77a712f8c801c4dc9d06d256dfc0e6)) ### Features -* **logger:** add logProperty, logMethodFull ([8b0317d](https://github.com/AliMD/vatr/commit/8b0317db88ed73604a27935a3a30cd5c31cb0804)) -* **logger:** complete refactor the logger with new API and fix show correct line number ([7efe8cf](https://github.com/AliMD/vatr/commit/7efe8cf0f566e148406f38fdd60fa3d747c9bc51)) - - - - - -# [0.3.0](https://github.com/AliMD/vatr/compare/v0.2.1...v0.3.0) (2022-03-06) - -**Note:** Version bump only for package @vatr/logger - +* **logger:** add logProperty, logMethodFull ([8b0317d](https://github.com/AliMD/alwatr/commit/8b0317db88ed73604a27935a3a30cd5c31cb0804)) +* **logger:** complete refactor the logger with new API and fix show correct line number ([7efe8cf](https://github.com/AliMD/alwatr/commit/7efe8cf0f566e148406f38fdd60fa3d747c9bc51)) +# [0.3.0](https://github.com/AliMD/alwatr/compare/v0.2.1...v0.3.0) (2022-03-06) +**Note:** Version bump only for package @alwatr/logger - -## [0.2.1](https://github.com/AliMD/vatr/compare/v0.2.0...v0.2.1) (2022-03-05) - +## [0.2.1](https://github.com/AliMD/alwatr/compare/v0.2.0...v0.2.1) (2022-03-05) ### Bug Fixes -* **logger:** vatrRegisteredList name ([ff59133](https://github.com/AliMD/vatr/commit/ff5913321c4eafa1ce53fdacebf8fb4f23bfe430)) - - - - - -# [0.2.0](https://github.com/AliMD/vatr/compare/v0.1.2...v0.2.0) (2022-03-05) - -**Note:** Version bump only for package @vatr/logger - - - - - -## [0.1.2](https://github.com/AliMD/vatr/compare/v0.1.1...v0.1.2) (2022-03-03) - -**Note:** Version bump only for package @vatr/logger +* **logger:** alwatrRegisteredList name ([ff59133](https://github.com/AliMD/alwatr/commit/ff5913321c4eafa1ce53fdacebf8fb4f23bfe430)) +# [0.2.0](https://github.com/AliMD/alwatr/compare/v0.1.2...v0.2.0) (2022-03-05) +**Note:** Version bump only for package @alwatr/logger +## [0.1.2](https://github.com/AliMD/alwatr/compare/v0.1.1...v0.1.2) (2022-03-03) +**Note:** Version bump only for package @alwatr/logger -## [0.1.1](https://github.com/AliMD/vatr/compare/v0.1.0...v0.1.1) (2022-03-03) +## [0.1.1](https://github.com/AliMD/alwatr/compare/v0.1.0...v0.1.1) (2022-03-03) ### Bug Fixes -* **packages:** add publish config to public ([9cb3710](https://github.com/AliMD/vatr/commit/9cb37106b5a35d24d5195ff54232e5769ccc034e)) +* **packages:** add publish config to public ([9cb3710](https://github.com/AliMD/alwatr/commit/9cb37106b5a35d24d5195ff54232e5769ccc034e)) # 0.1.0 (2022-03-02) ### Bug Fixes -* **logger:** fix debug scope ([be62f14](https://github.com/AliMD/vatr/commit/be62f142cbe3fe4d328e3fd9941ea7c2d640a23f)) -* **logger:** fix logger debug scope ([e734d21](https://github.com/AliMD/vatr/commit/e734d218db888ecec33a03dc805b98dd75543efd)) -* tsconfig issues ([159adeb](https://github.com/AliMD/vatr/commit/159adeb72de4626dc16f6657765605b0a2ddccb1)) +* **logger:** fix debug scope ([be62f14](https://github.com/AliMD/alwatr/commit/be62f142cbe3fe4d328e3fd9941ea7c2d640a23f)) +* **logger:** fix logger debug scope ([e734d21](https://github.com/AliMD/alwatr/commit/e734d218db888ecec33a03dc805b98dd75543efd)) +* tsconfig issues ([159adeb](https://github.com/AliMD/alwatr/commit/159adeb72de4626dc16f6657765605b0a2ddccb1)) ### Features -* **logger:** debug scope ([6e4190d](https://github.com/AliMD/vatr/commit/6e4190dc9dafc28e3a7a481aa43622a23527993c)) -* **logger:** debug scope logger package ([1a4baeb](https://github.com/AliMD/vatr/commit/1a4baeb7a253ba66563dbcf06079242dabb9f246)) -* **logger:** vatr logger package ([711268e](https://github.com/AliMD/vatr/commit/711268e17dea8ada9c901ef1e9d605b3212abd97)) -* **logger:** vatr meta structure ([feade73](https://github.com/AliMD/vatr/commit/feade735a6f141db77b81d7791d8872d45c8bf7e)) +* **logger:** debug scope ([6e4190d](https://github.com/AliMD/alwatr/commit/6e4190dc9dafc28e3a7a481aa43622a23527993c)) +* **logger:** debug scope logger package ([1a4baeb](https://github.com/AliMD/alwatr/commit/1a4baeb7a253ba66563dbcf06079242dabb9f246)) +* **logger:** alwatr logger package ([711268e](https://github.com/AliMD/alwatr/commit/711268e17dea8ada9c901ef1e9d605b3212abd97)) +* **logger:** alwatr meta structure ([feade73](https://github.com/AliMD/alwatr/commit/feade735a6f141db77b81d7791d8872d45c8bf7e)) diff --git a/package/logger/README.md b/package/logger/README.md index 69754a9ca..a7f2230fc 100644 --- a/package/logger/README.md +++ b/package/logger/README.md @@ -1,11 +1,11 @@ -# @vatr/logger +# @alwatr/logger Fancy colorful console debugger with custom scope written in tiny TypeScript, ES module. ## Example usage ```ts -import { createLogger } from 'https://esm.run/@vatr/logger'; +import { createLogger } from 'https://esm.run/@alwatr/logger'; const logger = createLogger('demo'); @@ -22,19 +22,19 @@ Please remember to **reload** the window after changing the debug mode. - Debugging all scopes ```ts - window.localStorage?.setItem('VATR_LOG', '*'); + window.localStorage?.setItem('ALWATR_LOG', '*'); ``` - Debugging specific scope ```ts - window.localStorage?.setItem('VATR_LOG', 'scope_name'); + window.localStorage?.setItem('ALWATR_LOG', 'scope_name'); ``` - Debugging some scopes with pattern ```ts - window.localStorage?.setItem('VATR_LOG', '*vatr*'); + window.localStorage?.setItem('ALWATR_LOG', '*alwatr*'); ``` ### API @@ -42,7 +42,7 @@ Please remember to **reload** the window after changing the debug mode. ### Prepare the logger ```ts -import {createLogger} from 'https://esm.run/@vatr/logger'; +import {createLogger} from 'https://esm.run/@alwatr/logger'; const logger = createLogger('logger/demo', 'green'); ``` diff --git a/package/logger/package.json b/package/logger/package.json index d6e7c2779..e09e4d6db 100644 --- a/package/logger/package.json +++ b/package/logger/package.json @@ -1,5 +1,5 @@ { - "name": "@vatr/logger", + "name": "@alwatr/logger", "version": "0.5.0", "description": "Fancy colorful console debugger with custom scope written in tiny TypeScript, ES module.", "keywords": [ @@ -9,8 +9,7 @@ "debug", "typescript", "esm", - "vatr", - "alvatr" + "alwatr" ], "main": "logger.js", "type": "module", @@ -29,12 +28,12 @@ }, "repository": { "type": "git", - "url": "https://github.com/AliMD/vatr", + "url": "https://github.com/AliMD/alwatr", "directory": "package/logger" }, - "homepage": "https://github.com/AliMD/vatr/tree/main/package/logger#readme", + "homepage": "https://github.com/AliMD/alwatr/tree/main/package/logger#readme", "bugs": { - "url": "https://github.com/AliMD/vatr/issues" + "url": "https://github.com/AliMD/alwatr/issues" }, "dependencies": { "tslib": "^2.3.1" diff --git a/package/logger/src/logger.ts b/package/logger/src/logger.ts index 984f91949..b681ffdee 100644 --- a/package/logger/src/logger.ts +++ b/package/logger/src/logger.ts @@ -1,15 +1,15 @@ import type {Logger} from './type'; /** - * Define `window.Vatr.registeredList` + * Define `window.Alwatr.registeredList` */ -export const vatrRegisteredList = window.Vatr?.registeredList || []; -window.Vatr ??= {}; -window.Vatr.registeredList = vatrRegisteredList; +export const alwatrRegisteredList = window.Alwatr?.registeredList || []; +window.Alwatr ??= {}; +window.Alwatr.registeredList = alwatrRegisteredList; -vatrRegisteredList.push({ - name: '@vatr/logger', - version: '{{VATR_VERSION}}', // TODO: replace with real version at release time. +alwatrRegisteredList.push({ + name: '@alwatr/logger', + version: '{{ALWATR_VERSION}}', // TODO: replace with real version at release time. }); /** @@ -43,7 +43,7 @@ const getNextColor = (): string => { return color; }; -const debugString = window.localStorage?.getItem('VATR_LOG')?.trim(); +const debugString = window.localStorage?.getItem('ALWATR_LOG')?.trim(); const getDebugState = (scope: string, force: boolean ): boolean => { if ( debugString == null || @@ -56,11 +56,11 @@ const getDebugState = (scope: string, force: boolean ): boolean => { force || debugString === scope || ( - debugString.indexOf('*') === 0 && // starts with `*` for example: `*vatr*` + debugString.indexOf('*') === 0 && // starts with `*` for example: `*alwatr*` scope.indexOf(debugString.replaceAll('*', '')) !== -1 ) || ( - debugString.indexOf('*') === debugString.length - 1 && // ends with `*` for example: `vatr/*` + debugString.indexOf('*') === debugString.length - 1 && // ends with `*` for example: `alwatr/*` scope.indexOf(debugString.replaceAll('*', '')) === 0 ) ) { diff --git a/package/logger/src/type.ts b/package/logger/src/type.ts index 3aeff880e..2428aeb58 100644 --- a/package/logger/src/type.ts +++ b/package/logger/src/type.ts @@ -1,6 +1,6 @@ declare global { interface Window { - Vatr?: { + Alwatr?: { registeredList?: Array<{ name: string, version: string, diff --git a/package/router/CHANGELOG.md b/package/router/CHANGELOG.md index 96503e3d3..70173c62e 100644 --- a/package/router/CHANGELOG.md +++ b/package/router/CHANGELOG.md @@ -3,61 +3,42 @@ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. -# [0.5.0](https://github.com/AliMD/vatr/compare/v0.4.0...v0.5.0) (2022-03-11) +# [0.5.0](https://github.com/AliMD/alwatr/compare/v0.4.0...v0.5.0) (2022-03-11) -**Note:** Version bump only for package @vatr/router - - - - - -# [0.4.0](https://github.com/AliMD/vatr/compare/v0.3.0...v0.4.0) (2022-03-11) +**Note:** Version bump only for package @alwatr/router +# [0.4.0](https://github.com/AliMD/alwatr/compare/v0.3.0...v0.4.0) (2022-03-11) ### Bug Fixes -* **router:** build issue for parameterList type [#75](https://github.com/AliMD/vatr/issues/75) ([5fc1ecd](https://github.com/AliMD/vatr/commit/5fc1ecd12b938936e2718f9307186493e2712e1f)) - - - - - -# [0.3.0](https://github.com/AliMD/vatr/compare/v0.2.1...v0.3.0) (2022-03-06) +* **router:** build issue for parameterList type [#75](https://github.com/AliMD/alwatr/issues/75) ([5fc1ecd](https://github.com/AliMD/alwatr/commit/5fc1ecd12b938936e2718f9307186493e2712e1f)) -**Note:** Version bump only for package @vatr/router +# [0.3.0](https://github.com/AliMD/alwatr/compare/v0.2.1...v0.3.0) (2022-03-06) +**Note:** Version bump only for package @alwatr/router +## [0.2.1](https://github.com/AliMD/alwatr/compare/v0.2.0...v0.2.1) (2022-03-05) +**Note:** Version bump only for package @alwatr/router - -## [0.2.1](https://github.com/AliMD/vatr/compare/v0.2.0...v0.2.1) (2022-03-05) - -**Note:** Version bump only for package @vatr/router - - - - - -# [0.2.0](https://github.com/AliMD/vatr/compare/v0.1.2...v0.2.0) (2022-03-05) - +# [0.2.0](https://github.com/AliMD/alwatr/compare/v0.1.2...v0.2.0) (2022-03-05) ### Bug Fixes -* **router:** trigger click signal name ([b4a9477](https://github.com/AliMD/vatr/commit/b4a9477464cb05bb8fa227014de5e8af5b8dd600)) - +* **router:** trigger click signal name ([b4a9477](https://github.com/AliMD/alwatr/commit/b4a9477464cb05bb8fa227014de5e8af5b8dd600)) ### Features -* **router:** _updateBrowserHistory ([8933a97](https://github.com/AliMD/vatr/commit/8933a97cde277708356fc123c7493774cf0b00ec)) -* **router:** base type ([f76d34b](https://github.com/AliMD/vatr/commit/f76d34b65fbfb9680662dd994136d90be99d496c)) -* **router:** first route request ([e0ad1d4](https://github.com/AliMD/vatr/commit/e0ad1d403f0023e2df44cb8b7a3a5710fcfbe877)) -* **router:** impeliment click trigger ([39f5f07](https://github.com/AliMD/vatr/commit/39f5f075f48ae4323ccca57467dde04ce8c9c3be)) -* **router:** impeliment popstate trigger ([1613131](https://github.com/AliMD/vatr/commit/16131312e4bc083ca3d6cf4c1458a93962946ccf)) -* **router:** initialRouter with trigers options ([802405f](https://github.com/AliMD/vatr/commit/802405fb17846be9fe51a41122c871b5aca9cf6b)) -* **router:** joinParameterList, splitParameterString ([9a4232b](https://github.com/AliMD/vatr/commit/9a4232b942f36a06cd3278e1a339639c9bcc82fa)) -* **router:** make new package for routing base on sognals ([39c9ae8](https://github.com/AliMD/vatr/commit/39c9ae8cf2d8288cfdefce0826f5fe89b2d7d550)) -* **router:** makeRouteObject ([6e0e5dc](https://github.com/AliMD/vatr/commit/6e0e5dc6fa10a6c02b1aeb198355040de6e235d2)) -* **router:** parseValue all sections and params value ([9af4079](https://github.com/AliMD/vatr/commit/9af4079f03dc2b656694f962701fcf75da23fa99)) -* **router:** requestRouteHref ([9341f3f](https://github.com/AliMD/vatr/commit/9341f3ff444bcdf26fd31f5eca71912dd70b7167)) -* **router:** route base types ([769e863](https://github.com/AliMD/vatr/commit/769e863b3a1569a01b320390b007bccaa80c3458)) -* **router:** routeSignalProvider ([ad187e7](https://github.com/AliMD/vatr/commit/ad187e706b6d62abd0668cf9bc7b64c49acab071)) +* **router:** _updateBrowserHistory ([8933a97](https://github.com/AliMD/alwatr/commit/8933a97cde277708356fc123c7493774cf0b00ec)) +* **router:** base type ([f76d34b](https://github.com/AliMD/alwatr/commit/f76d34b65fbfb9680662dd994136d90be99d496c)) +* **router:** first route request ([e0ad1d4](https://github.com/AliMD/alwatr/commit/e0ad1d403f0023e2df44cb8b7a3a5710fcfbe877)) +* **router:** implement click trigger ([39f5f07](https://github.com/AliMD/alwatr/commit/39f5f075f48ae4323ccca57467dde04ce8c9c3be)) +* **router:** implement popstate trigger ([1613131](https://github.com/AliMD/alwatr/commit/16131312e4bc083ca3d6cf4c1458a93962946ccf)) +* **router:** initialRouter with triggers options ([802405f](https://github.com/AliMD/alwatr/commit/802405fb17846be9fe51a41122c871b5aca9cf6b)) +* **router:** joinParameterList, splitParameterString ([9a4232b](https://github.com/AliMD/alwatr/commit/9a4232b942f36a06cd3278e1a339639c9bcc82fa)) +* **router:** make new package for routing base on signals ([39c9ae8](https://github.com/AliMD/alwatr/commit/39c9ae8cf2d8288cfdefce0826f5fe89b2d7d550)) +* **router:** makeRouteObject ([6e0e5dc](https://github.com/AliMD/alwatr/commit/6e0e5dc6fa10a6c02b1aeb198355040de6e235d2)) +* **router:** parseValue all sections and params value ([9af4079](https://github.com/AliMD/alwatr/commit/9af4079f03dc2b656694f962701fcf75da23fa99)) +* **router:** requestRouteHref ([9341f3f](https://github.com/AliMD/alwatr/commit/9341f3ff444bcdf26fd31f5eca71912dd70b7167)) +* **router:** route base types ([769e863](https://github.com/AliMD/alwatr/commit/769e863b3a1569a01b320390b007bccaa80c3458)) +* **router:** routeSignalProvider ([ad187e7](https://github.com/AliMD/alwatr/commit/ad187e706b6d62abd0668cf9bc7b64c49acab071)) diff --git a/package/router/README.md b/package/router/README.md index c0a9ad67a..f8ababd1a 100644 --- a/package/router/README.md +++ b/package/router/README.md @@ -1,10 +1,10 @@ -# @vatr/router +# @alwatr/router Elegant powerful router (fundamental advance browser page routing) based on the simplicity of the signals written in tiny TypeScript module. ## Example usage ```js -import { initialRouter } from 'https://esm.run/@vatr/router'; +import { initialRouter } from 'https://esm.run/@alwatr/router'; initialRouter(); ``` diff --git a/package/router/package.json b/package/router/package.json index 005d433a0..9d0e7d6f4 100644 --- a/package/router/package.json +++ b/package/router/package.json @@ -1,5 +1,5 @@ { - "name": "@vatr/router", + "name": "@alwatr/router", "version": "0.5.0", "description": "Elegant powerful router (fundamental advance browser page routing) based on the simplicity of the signals written in tiny TypeScript module.", "keywords": [ @@ -8,8 +8,7 @@ "routing", "typescript", "esm", - "vatr", - "alvatr" + "alwatr" ], "main": "router.js", "type": "module", @@ -29,16 +28,16 @@ }, "repository": { "type": "git", - "url": "https://github.com/AliMD/vatr", + "url": "https://github.com/AliMD/alwatr", "directory": "package/router" }, - "homepage": "https://github.com/AliMD/vatr/tree/main/package/router#readme", + "homepage": "https://github.com/AliMD/alwatr/tree/main/package/router#readme", "bugs": { - "url": "https://github.com/AliMD/vatr/issues" + "url": "https://github.com/AliMD/alwatr/issues" }, "dependencies": { - "@vatr/logger": "^0.5.0", - "@vatr/signal": "^0.5.0", + "@alwatr/logger": "^0.5.0", + "@alwatr/signal": "^0.5.0", "tslib": "^2.3.1" } } diff --git a/package/router/src/core.ts b/package/router/src/core.ts index cf08e68d1..5de170fcd 100644 --- a/package/router/src/core.ts +++ b/package/router/src/core.ts @@ -1,13 +1,13 @@ -import {SignalInterface} from '@vatr/signal'; -import {createLogger, vatrRegisteredList} from '@vatr/logger'; +import {SignalInterface} from '@alwatr/signal'; +import {createLogger, alwatrRegisteredList} from '@alwatr/logger'; import type {ParamList, RequestRouteParam, Route} from './type'; -vatrRegisteredList.push({ - name: '@vatr/router', - version: '{{VATR_VERSION}}', +alwatrRegisteredList.push({ + name: '@alwatr/router', + version: '{{ALWATR_VERSION}}', }); -export const logger = createLogger('vatr/router'); +export const logger = createLogger('alwatr/router'); export const routerChangeSignal = new SignalInterface('router-change'); diff --git a/package/router/src/trigger-click.ts b/package/router/src/trigger-click.ts index 1a326800e..afdf73494 100644 --- a/package/router/src/trigger-click.ts +++ b/package/router/src/trigger-click.ts @@ -3,14 +3,14 @@ import {logger, routerChangeSignal} from './core'; let _enabled = false; /** - * A navigation trigger for Vatr Router that translated clicks on `` links into navigation signal. + * A navigation trigger for Alwatr Router that translated clicks on `` links into navigation signal. * * Only regular clicks on in-app links are translated. * Only primary mouse button, no modifier keys, the target href is within the app's URL space. */ export const clickTrigger = { /** - * Vatr router global click handler. + * Alwatr router global click handler. */ _clickHandler(event: MouseEvent): void { if ( diff --git a/package/router/src/trigger-popstate.ts b/package/router/src/trigger-popstate.ts index 17f8f0f92..3da98429e 100644 --- a/package/router/src/trigger-popstate.ts +++ b/package/router/src/trigger-popstate.ts @@ -3,14 +3,14 @@ import {logger, routerChangeSignal} from './core'; let _enabled = false; /** - * A navigation trigger for Vatr Router that translates popstate events into navigation signal. + * A navigation trigger for Alwatr Router that translates popstate events into navigation signal. */ export const popstateTrigger = { /** - * Vatr router global popstate handler. + * Alwatr router global popstate handler. */ _popstateHandler(event: PopStateEvent): void { - if (event.state === 'vatr-router-ignore') { + if (event.state === 'alwatr-router-ignore') { return; } // if none of the above, convert the click into a navigation signal. diff --git a/package/router/src/type.ts b/package/router/src/type.ts index b343cc34c..3eb6ca656 100644 --- a/package/router/src/type.ts +++ b/package/router/src/type.ts @@ -1,9 +1,9 @@ declare global { - interface VatrSignals { + interface AlwatrSignals { 'router-change': Route; } - interface VatrRequestSignals { + interface AlwatrRequestSignals { 'router-change': RequestRouteParam; } } @@ -37,7 +37,7 @@ export interface RequestRouteParam { */ export interface InitOptions { /** - * A navigation trigger for Vatr Router that translated clicks on `` links into navigation signal. + * A navigation trigger for Alwatr Router that translated clicks on `` links into navigation signal. * * Only regular clicks on in-app links are translated. * Only primary mouse button, no modifier keys, the target href is within the app's URL space. diff --git a/package/signal/CHANGELOG.md b/package/signal/CHANGELOG.md index ea5449d04..d11f4d9f3 100644 --- a/package/signal/CHANGELOG.md +++ b/package/signal/CHANGELOG.md @@ -3,98 +3,98 @@ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. -# [0.5.0](https://github.com/AliMD/vatr/compare/v0.4.0...v0.5.0) (2022-03-11) +# [0.5.0](https://github.com/AliMD/alwatr/compare/v0.4.0...v0.5.0) (2022-03-11) ### Bug Fixes -* **signal:** disabled getter and optional dispatch options ([28ced3d](https://github.com/AliMD/vatr/commit/28ced3d0c4cdf44fc2aebfab98db0883fc5363fe)) +* **signal:** disabled getter and optional dispatch options ([28ced3d](https://github.com/AliMD/alwatr/commit/28ced3d0c4cdf44fc2aebfab98db0883fc5363fe)) ### Features -* **signal:** new SignalInterface ([221701a](https://github.com/AliMD/vatr/commit/221701a54ea9edda4a3a935a7b098e235ec52691)) +* **signal:** new SignalInterface ([221701a](https://github.com/AliMD/alwatr/commit/221701a54ea9edda4a3a935a7b098e235ec52691)) -# [0.4.0](https://github.com/AliMD/vatr/compare/v0.3.0...v0.4.0) (2022-03-11) +# [0.4.0](https://github.com/AliMD/alwatr/compare/v0.3.0...v0.4.0) (2022-03-11) -**Note:** Version bump only for package @vatr/signal +**Note:** Version bump only for package @alwatr/signal -# [0.3.0](https://github.com/AliMD/vatr/compare/v0.2.1...v0.3.0) (2022-03-06) +# [0.3.0](https://github.com/AliMD/alwatr/compare/v0.2.1...v0.3.0) (2022-03-06) ### Bug Fixes -* **signal:** signal provider type ([0151c57](https://github.com/AliMD/vatr/commit/0151c57d9b6d4f7e83bb9b1847ebe0ae53cd8f89)) +* **signal:** signal provider type ([0151c57](https://github.com/AliMD/alwatr/commit/0151c57d9b6d4f7e83bb9b1847ebe0ae53cd8f89)) -## [0.2.1](https://github.com/AliMD/vatr/compare/v0.2.0...v0.2.1) (2022-03-05) +## [0.2.1](https://github.com/AliMD/alwatr/compare/v0.2.0...v0.2.1) (2022-03-05) ### Bug Fixes -* **signal:** signal value type issue ([292a4a7](https://github.com/AliMD/vatr/commit/292a4a7d12a2fd143761e67cd1ecd2e5e40f2ee9)) +* **signal:** signal value type issue ([292a4a7](https://github.com/AliMD/alwatr/commit/292a4a7d12a2fd143761e67cd1ecd2e5e40f2ee9)) -# [0.2.0](https://github.com/AliMD/vatr/compare/v0.1.2...v0.2.0) (2022-03-05) +# [0.2.0](https://github.com/AliMD/alwatr/compare/v0.1.2...v0.2.0) (2022-03-05) ### Bug Fixes -* **router:** rename setSignalProvider callback detail to requestParam ([6e09f87](https://github.com/AliMD/vatr/commit/6e09f8772d320625fb4c15ccaa0abcfa2932f992)) -* **signal:** fix dispatchSignal value parameters ([4d34cfb](https://github.com/AliMD/vatr/commit/4d34cfbb5281d5ce4a4f06ddaaf72218dde80cdd)) +* **router:** rename setSignalProvider callback detail to requestParam ([6e09f87](https://github.com/AliMD/alwatr/commit/6e09f8772d320625fb4c15ccaa0abcfa2932f992)) +* **signal:** fix dispatchSignal value parameters ([4d34cfb](https://github.com/AliMD/alwatr/commit/4d34cfbb5281d5ce4a4f06ddaaf72218dde80cdd)) ### Features -* **signal:** add contributors ([64287cd](https://github.com/AliMD/vatr/commit/64287cd8cea95665a6ed298177df60dadda7642b)) -* **signal:** improve signal provider by dispatch return content ([80c2b27](https://github.com/AliMD/vatr/commit/80c2b275bcc0521327400c5902f512c778f5eb3f)) +* **signal:** add contributors ([64287cd](https://github.com/AliMD/alwatr/commit/64287cd8cea95665a6ed298177df60dadda7642b)) +* **signal:** improve signal provider by dispatch return content ([80c2b27](https://github.com/AliMD/alwatr/commit/80c2b275bcc0521327400c5902f512c778f5eb3f)) -## [0.1.2](https://github.com/AliMD/vatr/compare/v0.1.1...v0.1.2) (2022-03-03) +## [0.1.2](https://github.com/AliMD/alwatr/compare/v0.1.1...v0.1.2) (2022-03-03) -**Note:** Version bump only for package @vatr/signal +**Note:** Version bump only for package @alwatr/signal -## [0.1.1](https://github.com/AliMD/vatr/compare/v0.1.0...v0.1.1) (2022-03-03) +## [0.1.1](https://github.com/AliMD/alwatr/compare/v0.1.0...v0.1.1) (2022-03-03) ### Bug Fixes -* **packages:** add publish config to public ([9cb3710](https://github.com/AliMD/vatr/commit/9cb37106b5a35d24d5195ff54232e5769ccc034e)) +* **packages:** add publish config to public ([9cb3710](https://github.com/AliMD/alwatr/commit/9cb37106b5a35d24d5195ff54232e5769ccc034e)) # 0.1.0 (2022-03-02) ### Bug Fixes -* **signal:** VatrRequestSignals global type ([228e333](https://github.com/AliMD/vatr/commit/228e3333326b23df51e7834872daf1349826bf09)) +* **signal:** AlwatrRequestSignals global type ([228e333](https://github.com/AliMD/alwatr/commit/228e3333326b23df51e7834872daf1349826bf09)) ### Features -* **signal:** addSignalListener ([e7c5742](https://github.com/AliMD/vatr/commit/e7c57427ef11e2624eb9a52a166720b1a3c5f66a)) -* **signal:** getSignalObject ([b38954c](https://github.com/AliMD/vatr/commit/b38954cf4ae1c24eaaa79ecf513995a4678814ee)) -* **signal:** impeliment addSignalProvider, waitForSignal, hasSignalDispatchedBefore, expireSignal ([e0b4d78](https://github.com/AliMD/vatr/commit/e0b4d7831764d4454591f5105c5512e1657a63e5)) -* **signal:** impeliment dispatchSignal ([cb2dfbe](https://github.com/AliMD/vatr/commit/cb2dfbe23ea751cba93cb1f6516cd2bfa2ecb18e)) -* **signal:** ListenerObject, SignalObject types ([36d8a33](https://github.com/AliMD/vatr/commit/36d8a336760bba3808cfd26a28e4d24a31c95f8f)) -* **signal:** make new package for manage signals ([5bf82b3](https://github.com/AliMD/vatr/commit/5bf82b3f05abc89102634e9b864d81b5b5af527e)) -* **signal:** register to vatr meta ([9c850e8](https://github.com/AliMD/vatr/commit/9c850e8df787aa44d289929dc65439e921982dce)) -* **signal:** removeSignalListener ([0088a52](https://github.com/AliMD/vatr/commit/0088a5269ccce8b50a50e444695c81654fda70ff)) -* **signal:** requestSignal ([111ab5a](https://github.com/AliMD/vatr/commit/111ab5a1436bc380f5121ef8c130da7010258d90)) +* **signal:** addSignalListener ([e7c5742](https://github.com/AliMD/alwatr/commit/e7c57427ef11e2624eb9a52a166720b1a3c5f66a)) +* **signal:** getSignalObject ([b38954c](https://github.com/AliMD/alwatr/commit/b38954cf4ae1c24eaaa79ecf513995a4678814ee)) +* **signal:** impeliment addSignalProvider, waitForSignal, hasSignalDispatchedBefore, expireSignal ([e0b4d78](https://github.com/AliMD/alwatr/commit/e0b4d7831764d4454591f5105c5512e1657a63e5)) +* **signal:** impeliment dispatchSignal ([cb2dfbe](https://github.com/AliMD/alwatr/commit/cb2dfbe23ea751cba93cb1f6516cd2bfa2ecb18e)) +* **signal:** ListenerObject, SignalObject types ([36d8a33](https://github.com/AliMD/alwatr/commit/36d8a336760bba3808cfd26a28e4d24a31c95f8f)) +* **signal:** make new package for manage signals ([5bf82b3](https://github.com/AliMD/alwatr/commit/5bf82b3f05abc89102634e9b864d81b5b5af527e)) +* **signal:** register to alwatr meta ([9c850e8](https://github.com/AliMD/alwatr/commit/9c850e8df787aa44d289929dc65439e921982dce)) +* **signal:** removeSignalListener ([0088a52](https://github.com/AliMD/alwatr/commit/0088a5269ccce8b50a50e444695c81654fda70ff)) +* **signal:** requestSignal ([111ab5a](https://github.com/AliMD/alwatr/commit/111ab5a1436bc380f5121ef8c130da7010258d90)) diff --git a/package/signal/README.md b/package/signal/README.md index 6cb3bc98b..bd6d2761f 100644 --- a/package/signal/README.md +++ b/package/signal/README.md @@ -1,4 +1,4 @@ -# @vatr/signal +# @alwatr/signal Elegant powerful event system for handle global signals and states written in tiny TypeScript module. @@ -6,21 +6,21 @@ Every signal has own value and can be used as a advance **state management** lik ## Example usage -### Add your signal name to global `VatrSignals` type helper +### Add your signal name to global `AlwatrSignals` type helper ```ts declare global { /** * Global signals value type registry. */ - interface VatrSignals { + interface AlwatrSignals { readonly 'content-change': Record; } /** * Global request signal parameters types. */ - interface VatrRequestSignals { + interface AlwatrRequestSignals { readonly 'content-change': number; } } @@ -29,7 +29,7 @@ declare global { ### Dispatch signal with value ```ts -import {SignalInterface} from 'https://esm.run/@vatr/signal'; +import {SignalInterface} from 'https://esm.run/@alwatr/signal'; const contentChangeSignal1 = new SignalInterface('content-change'); @@ -44,7 +44,7 @@ contentChangeSignal1.dispatch({a:3, b:4}); ### Receive the signal value ```ts -import {SignalInterface} from 'https://esm.run/@vatr/signal'; +import {SignalInterface} from 'https://esm.run/@alwatr/signal'; const contentChangeSignal2 = new SignalInterface('content-change'); // Same share signal as contentChangeSignal1 @@ -60,7 +60,7 @@ contentChangeSignal2.addListener((content) => { #### `new SignalInterface(signal-name)` ```ts -import {SignalInterface} from 'https://esm.run/@vatr/signal'; +import {SignalInterface} from 'https://esm.run/@alwatr/signal'; const contentChangeSignal = new SignalInterface('content-change'); ``` diff --git a/package/signal/package.json b/package/signal/package.json index 291579f85..2561fa22e 100644 --- a/package/signal/package.json +++ b/package/signal/package.json @@ -1,13 +1,12 @@ { - "name": "@vatr/signal", + "name": "@alwatr/signal", "version": "0.5.0", "description": "Elegant powerful event system for handle global signals and states written in tiny TypeScript module.", "keywords": [ "signal", "typescript", "esm", - "vatr", - "alvatr" + "alwatr" ], "main": "signal.js", "type": "module", @@ -29,15 +28,15 @@ }, "repository": { "type": "git", - "url": "https://github.com/AliMD/vatr", + "url": "https://github.com/AliMD/alwatr", "directory": "package/signal" }, - "homepage": "https://github.com/AliMD/vatr/tree/main/package/signal#readme", + "homepage": "https://github.com/AliMD/alwatr/tree/main/package/signal#readme", "bugs": { - "url": "https://github.com/AliMD/vatr/issues" + "url": "https://github.com/AliMD/alwatr/issues" }, "dependencies": { - "@vatr/logger": "^0.5.0", + "@alwatr/logger": "^0.5.0", "tslib": "^2.3.1" } } diff --git a/package/signal/src/core.ts b/package/signal/src/core.ts index b0d810ef9..fcb95840e 100644 --- a/package/signal/src/core.ts +++ b/package/signal/src/core.ts @@ -1,4 +1,4 @@ -import {createLogger, vatrRegisteredList} from '@vatr/logger'; +import {createLogger, alwatrRegisteredList} from '@alwatr/logger'; import type { DispatchOptions, ListenerCallback, @@ -10,11 +10,11 @@ import type { SignalStack, } from './type'; -export const logger = createLogger('vatr/signal'); +export const logger = createLogger('alwatr/signal'); -vatrRegisteredList.push({ - name: '@vatr/signal', - version: '{{VATR_VERSION}}', +alwatrRegisteredList.push({ + name: '@alwatr/signal', + version: '{{ALWATR_VERSION}}', }); /** @@ -25,7 +25,7 @@ const _signalStack: SignalStack = {}; /** * Access to signal option, Make new signal with default options if not exist. */ -export function __getSignalObject( +export function __getSignalObject( signalName: SignalName, ): SignalObject { if (!_signalStack[signalName]) { @@ -39,7 +39,7 @@ export function __getSignalObject( return _signalStack[signalName] as unknown as SignalObject; } -function __callListeners( +function __callListeners( signal: SignalObject, ): void { logger.logMethodArgs('_callListeners', {signalName: signal.name, signalValue: signal.value}); @@ -72,7 +72,7 @@ function __callListeners( * const listener = addSignalListener('content-change', (content) => console.log(content)); * ``` */ -export function _addSignalListener( +export function _addSignalListener( signalName: SignalName, signalCallback: ListenerCallback, options?: ListenerOptions, @@ -81,7 +81,7 @@ export function _addSignalListener( const signal = __getSignalObject(signalName); const listener: ListenerObject = { - id: Symbol('Vatr signal listener for ' + signalName), + id: Symbol('Alwatr signal listener for ' + signalName), once: options?.once ?? false, disabled: options?.disabled ?? false, callback: signalCallback, @@ -134,7 +134,7 @@ export function _addSignalListener( * removeSignalListener('content-change', listener); * ``` */ -export function _removeSignalListener( +export function _removeSignalListener( signalName: SignalName, listenerId: symbol, ): void { @@ -152,9 +152,9 @@ export function _removeSignalListener( * @example * dispatchSignal('content-change', content); */ -export function _dispatchSignal( +export function _dispatchSignal( signalName: SignalName, - value: VatrSignals[SignalName], + value: AlwatrSignals[SignalName], options?: DispatchOptions, ): void { logger.logMethodArgs('dispatchSignal', {signalName, value, options}); @@ -196,7 +196,7 @@ export function _dispatchSignal( * } * ``` */ -export function _setSignalProvider( +export function _setSignalProvider( signalName: SignalName, signalProvider: SignalProvider, options?: SignalProviderOptions, @@ -211,7 +211,7 @@ export function _setSignalProvider( signal.listenerList = []; } - const _callback = async (requestParam: VatrRequestSignals[SignalName]): Promise => { + const _callback = async (requestParam: AlwatrRequestSignals[SignalName]): Promise => { const signalValue = await signalProvider(requestParam); if (signalValue !== undefined) { // null can be a valid value. _dispatchSignal(signalName, signalValue, {debounce: options?.debounce ?? true}); diff --git a/package/signal/src/signal.ts b/package/signal/src/signal.ts index 2383b6102..25668e948 100644 --- a/package/signal/src/signal.ts +++ b/package/signal/src/signal.ts @@ -1,4 +1,4 @@ -import {createLogger} from '@vatr/logger'; +import {createLogger} from '@alwatr/logger'; import { __getSignalObject, _removeSignalListener, @@ -18,7 +18,7 @@ import type { /** * Signal API interface as a remote controller. */ -export class SignalInterface { +export class SignalInterface { private _signal; private _logger; @@ -53,7 +53,7 @@ export class SignalInterface { * } * ``` */ - get value(): VatrSignals[SignalName] | undefined { + get value(): AlwatrSignals[SignalName] | undefined { return this._signal.value; } @@ -147,11 +147,11 @@ export class SignalInterface { * const newContent = await contentChangeSignal.request({foo: 'bar'}); * ``` */ - request(requestParam: VatrRequestSignals[SignalName]): Promise { + request(requestParam: AlwatrRequestSignals[SignalName]): Promise { this._logger.logMethodArgs('request', {requestParam}); _dispatchSignal( `request-${this.name}` as unknown as SignalName, - requestParam as unknown as VatrSignals[SignalName], // mastmalize to avoid type error + requestParam as unknown as AlwatrSignals[SignalName], // mastmalize to avoid type error ); return this.getNextSignalValue(); } @@ -167,7 +167,7 @@ export class SignalInterface { * const newContent = await contentChangeSignal.getNextSignalValue(); * ``` */ - getNextSignalValue(): Promise { + getNextSignalValue(): Promise { this._logger.logMethod('getNextSignalValue'); return new Promise((resolve) => { this.addListener(resolve, { @@ -191,7 +191,7 @@ export class SignalInterface { * const content = await contentChangeSignal.getSignalValue(); * ``` */ - getSignalValue(): Promise { + getSignalValue(): Promise { this._logger.logMethod('getSignalValue'); if (this._signal.value !== undefined) { return Promise.resolve(this._signal.value); @@ -210,7 +210,7 @@ export class SignalInterface { * contentChangeSignal.dispatch(content); * ``` */ - dispatch(signalValue: VatrSignals[SignalName], options?: DispatchOptions): void { + dispatch(signalValue: AlwatrSignals[SignalName], options?: DispatchOptions): void { this._logger.logMethodArgs('dispatch', {signalValue, options}); _dispatchSignal(this._signal.name, signalValue, options); } diff --git a/package/signal/src/type.ts b/package/signal/src/type.ts index fddb16089..c5f586ce4 100644 --- a/package/signal/src/type.ts +++ b/package/signal/src/type.ts @@ -2,14 +2,14 @@ declare global { /** * Global signals value type registry. */ - interface VatrSignals { + interface AlwatrSignals { readonly 'easter-egg': number; } /** * Global request signal parameters types. */ - interface VatrRequestSignals { + interface AlwatrRequestSignals { readonly 'easter-egg': number; } } @@ -82,20 +82,20 @@ export interface SignalProviderOptions { /** * Signal listeners callback function type. */ -export type ListenerCallback = - (signalValue: VatrSignals[SignalName]) => void | Promise; +export type ListenerCallback = + (signalValue: AlwatrSignals[SignalName]) => void | Promise; /** * Signal provider function type used to setSignalProvider. */ -export type SignalProvider = - (requestParam: VatrRequestSignals[SignalName]) => - VatrSignals[SignalName] | void | Promise; +export type SignalProvider = + (requestParam: AlwatrRequestSignals[SignalName]) => + AlwatrSignals[SignalName] | void | Promise; /** * Signal listeners object in database. */ -export interface ListenerObject +export interface ListenerObject { /** * Listener symbol id (unique). @@ -118,7 +118,7 @@ export interface ListenerObject /** * Signal object in database. */ -export interface SignalObject +export interface SignalObject { /** * Signal name for direct access. @@ -128,7 +128,7 @@ export interface SignalObject /** * Last dispatched value. */ - value?: VatrSignals[SignalName]; + value?: AlwatrSignals[SignalName]; /** * If true, the signal is disabled. @@ -151,5 +151,5 @@ export interface SignalObject * Signal stack database. */ export type SignalStack = { - [SignalName in keyof VatrSignals]?: SignalObject; + [SignalName in keyof AlwatrSignals]?: SignalObject; }