@angular/fire 21.0.0-rc.0-canary.97f61a4 → 21.0.0-rc.0-canary.36bab40
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/docs/ai.md
CHANGED
|
@@ -8,7 +8,7 @@ Firebase AI Logic gives you access to the latest generative AI models from Googl
|
|
|
8
8
|
|
|
9
9
|
[Learn more](https://firebase.google.com/docs/ai-logic)
|
|
10
10
|
|
|
11
|
-
> Firebase AI Logic was previously called **Vertex AI in Firebase**. If you are upgrading from AngularFire 20, the module moved from `@angular/fire/vertexai` to `@angular/fire/ai` and most symbols were renamed (`provideVertexAI` to `provideAI`, `VertexAI` to `AI`). One is not a rename: plain `getAI()` uses the Gemini Developer API backend, so the old `getVertexAI()` maps to `getAI(app, { backend: new
|
|
11
|
+
> Firebase AI Logic was previously called **Vertex AI in Firebase**. If you are upgrading from AngularFire 20, the module moved from `@angular/fire/vertexai` to `@angular/fire/ai` and most symbols were renamed (`provideVertexAI` to `provideAI`, `VertexAI` to `AI`). One is not a rename: plain `getAI()` uses the Gemini Developer API backend, so the old `getVertexAI()` maps to `getAI(app, { backend: new AgentPlatformBackend() })`. Running `ng update @angular/fire` rewrites all of this for you and keeps your app on the same backend, though a call that passed no `location` moves from `us-central1` to `global`. See the [AngularFire 20 to 21 upgrade guide](./version-21-upgrade.md).
|
|
12
12
|
|
|
13
13
|
## Dependency Injection
|
|
14
14
|
|
|
@@ -20,7 +20,7 @@ The Vertex AI module has been renamed to Firebase AI Logic. The `@angular/fire/v
|
|
|
20
20
|
|
|
21
21
|
| Before (`@angular/fire/vertexai`) | After (`@angular/fire/ai`) |
|
|
22
22
|
|---|---|
|
|
23
|
-
| `getVertexAI(app?, { location? })` | `getAI(app, { backend: new
|
|
23
|
+
| `getVertexAI(app?, { location? })` | `getAI(app, { backend: new AgentPlatformBackend(location?) })` |
|
|
24
24
|
| `provideVertexAI` | `provideAI` |
|
|
25
25
|
| `VertexAI` | `AI` |
|
|
26
26
|
| `VertexAIError` | `AIError` |
|
|
@@ -30,7 +30,30 @@ The Vertex AI module has been renamed to Firebase AI Logic. The `@angular/fire/v
|
|
|
30
30
|
| `vertexAIInstance$` | `AIInstance$` |
|
|
31
31
|
| `VertexAIModule` | `AIModule` |
|
|
32
32
|
|
|
33
|
-
|
|
33
|
+
### `getVertexAI` is not a plain rename
|
|
34
|
+
|
|
35
|
+
`getAI` already existed alongside it, and a plain `getAI()` call talks to the Gemini Developer API backend, not to the Agent Platform Gemini API (formerly Vertex AI). The equivalent of `getVertexAI()` is `getAI(app, { backend: new AgentPlatformBackend() })`, which is what the migration writes, so your app keeps calling the backend it was configured, enabled, and billed for. A `location` option moves into the `AgentPlatformBackend` constructor.
|
|
36
|
+
|
|
37
|
+
### The default region changes
|
|
38
|
+
|
|
39
|
+
`getVertexAI()` with no `location` resolved to `us-central1`. `AgentPlatformBackend` with no argument resolves to `global`. Firebase suggests `global` when your model supports it, and the Gemini 3.x models are only available there, which is why the migration writes it. To keep the region you had instead, write `new AgentPlatformBackend('us-central1')`.
|
|
40
|
+
|
|
41
|
+
Review this before deploying if your project has a data residency requirement.
|
|
42
|
+
|
|
43
|
+
#### Which calls move, and what the migration tells you
|
|
44
|
+
|
|
45
|
+
- A call that passed a non-empty `location` string keeps it, so its region does not move.
|
|
46
|
+
- A call that passed no `location`, or an empty one, moves to `global`. `getVertexAI` treated an empty value as `us-central1`, and `AgentPlatformBackend` treats it as `global`. The migration drops the empty value rather than writing it through, and warns.
|
|
47
|
+
- A call whose `location` is an expression the migration cannot read gets its own warning, because only your runtime knows whether that value is empty.
|
|
48
|
+
- A call whose options the migration cannot rewrite at all, such as a quoted `{ 'location': ... }` key, is left as written and warned about separately. Its import still moves, so it stops compiling until you migrate it by hand.
|
|
49
|
+
|
|
50
|
+
Each of those warnings is emitted once per file, so a file that has both a moved region and an unreadable `location` produces two.
|
|
51
|
+
|
|
52
|
+
#### If your app uses the Live API, do not stay on `global`
|
|
53
|
+
|
|
54
|
+
Firebase does not support the `global` location for the Live API models, so `getLiveGenerativeModel` and `startAudioConversation` stop working there. When the migration sees either of them anywhere in your workspace it says so in the region warning. Pass `'us-central1'`, or another supported location, to `AgentPlatformBackend`.
|
|
55
|
+
|
|
56
|
+
### What the migration rewrites for you
|
|
34
57
|
|
|
35
58
|
`ng update @angular/fire` rewrites these imports and identifiers for you and logs every `getVertexAI` call it rewrites. `getGenerativeModel` keeps its name.
|
|
36
59
|
|
|
@@ -42,7 +65,7 @@ Code the migration cannot rewrite safely is left in place with a warning. The im
|
|
|
42
65
|
|
|
43
66
|
- **Options it cannot read:** when the `getVertexAI` call's options are not a literal `{ location }` object, or that literal references other symbols the migration is also rewriting.
|
|
44
67
|
- **The function used as a value:** when `getVertexAI` is stored or passed around rather than called directly.
|
|
45
|
-
- **Name collisions:** when a local declaration in the file reuses an imported symbol's name, or the file already gets `getAI` or `
|
|
68
|
+
- **Name collisions:** when a local declaration in the file reuses an imported symbol's name, or the file already gets `getAI` or `AgentPlatformBackend` from a source other than AI Logic.
|
|
46
69
|
- **Wildcard re-exports:** when a file has `export * from '@angular/fire/vertexai'`, that line stays as written, because rewriting it would silently rename your re-exported public symbols. Replace it with named re-exports by hand.
|
|
47
70
|
|
|
48
71
|
A file where a named `getVertexAI` import is used in a way that cannot be rewritten keeps every use of its named `getVertexAI` imports in place (namespace-style `ns.getVertexAI(...)` calls are judged per call), and each skipped call is logged.
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "../node_modules/ng-packagr/package.schema.json",
|
|
3
3
|
"name": "@angular/fire",
|
|
4
|
-
"version": "21.0.0-rc.0-canary.
|
|
4
|
+
"version": "21.0.0-rc.0-canary.36bab40",
|
|
5
5
|
"description": "Angular + Firebase = ❤️",
|
|
6
6
|
"publishConfig": {
|
|
7
7
|
"registry": "https://wombat-dressing-room.appspot.com",
|
package/schematics/add/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
var mt=Object.create;var G=Object.defineProperty;var $t=Object.getOwnPropertyDescriptor;var Rt=Object.getOwnPropertyNames;var dt=Object.getPrototypeOf,It=Object.prototype.hasOwnProperty;var p=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),gt=(t,e)=>{for(var r in e)G(t,r,{get:e[r],enumerable:!0})},ge=(t,e,r,s)=>{if(e&&typeof e=="object"||typeof e=="function")for(let n of Rt(e))!It.call(t,n)&&n!==r&&G(t,n,{get:()=>e[n],enumerable:!(s=$t(e,n))||s.enumerable});return t};var Lt=(t,e,r)=>(r=t!=null?mt(dt(t)):{},ge(e||!t||!t.__esModule?G(r,"default",{value:t,enumerable:!0}):r,t)),Nt=t=>ge(G({},"__esModule",{value:!0}),t);var P=p((Oi,Le)=>{"use strict";var St="2.0.0",Ot=Number.MAX_SAFE_INTEGER||9007199254740991,Tt=16,At=250,wt=["major","premajor","minor","preminor","patch","prepatch","prerelease"];Le.exports={MAX_LENGTH:256,MAX_SAFE_COMPONENT_LENGTH:Tt,MAX_SAFE_BUILD_LENGTH:At,MAX_SAFE_INTEGER:Ot,RELEASE_TYPES:wt,SEMVER_SPEC_VERSION:St,FLAG_INCLUDE_PRERELEASE:1,FLAG_LOOSE:2}});var x=p((Ti,Ne)=>{"use strict";var qt=typeof process=="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?(...t)=>console.error("SEMVER",...t):()=>{};Ne.exports=qt});var q=p((T,Se)=>{"use strict";var{MAX_SAFE_COMPONENT_LENGTH:ee,MAX_SAFE_BUILD_LENGTH:vt,MAX_LENGTH:Pt}=P(),xt=x();T=Se.exports={};var Ct=T.re=[],Dt=T.safeRe=[],c=T.src=[],yt=T.safeSrc=[],l=T.t={},jt=0,re="[a-zA-Z0-9-]",Ft=[["\\s",1],["\\d",Pt],[re,vt]],Gt=t=>{for(let[e,r]of Ft)t=t.split(`${e}*`).join(`${e}{0,${r}}`).split(`${e}+`).join(`${e}{1,${r}}`);return t},m=(t,e,r)=>{let s=Gt(e),n=jt++;xt(t,n,e),l[t]=n,c[n]=e,yt[n]=s,Ct[n]=new RegExp(e,r?"g":void 0),Dt[n]=new RegExp(s,r?"g":void 0)};m("NUMERICIDENTIFIER","0|[1-9]\\d*");m("NUMERICIDENTIFIERLOOSE","\\d+");m("NONNUMERICIDENTIFIER",`\\d*[a-zA-Z-]${re}*`);m("MAINVERSION",`(${c[l.NUMERICIDENTIFIER]})\\.(${c[l.NUMERICIDENTIFIER]})\\.(${c[l.NUMERICIDENTIFIER]})`);m("MAINVERSIONLOOSE",`(${c[l.NUMERICIDENTIFIERLOOSE]})\\.(${c[l.NUMERICIDENTIFIERLOOSE]})\\.(${c[l.NUMERICIDENTIFIERLOOSE]})`);m("PRERELEASEIDENTIFIER",`(?:${c[l.NONNUMERICIDENTIFIER]}|${c[l.NUMERICIDENTIFIER]})`);m("PRERELEASEIDENTIFIERLOOSE",`(?:${c[l.NONNUMERICIDENTIFIER]}|${c[l.NUMERICIDENTIFIERLOOSE]})`);m("PRERELEASE",`(?:-(${c[l.PRERELEASEIDENTIFIER]}(?:\\.${c[l.PRERELEASEIDENTIFIER]})*))`);m("PRERELEASELOOSE",`(?:-?(${c[l.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${c[l.PRERELEASEIDENTIFIERLOOSE]})*))`);m("BUILDIDENTIFIER",`${re}+`);m("BUILD",`(?:\\+(${c[l.BUILDIDENTIFIER]}(?:\\.${c[l.BUILDIDENTIFIER]})*))`);m("FULLPLAIN",`v?${c[l.MAINVERSION]}${c[l.PRERELEASE]}?${c[l.BUILD]}?`);m("FULL",`^${c[l.FULLPLAIN]}$`);m("LOOSEPLAIN",`[v=\\s]*${c[l.MAINVERSIONLOOSE]}${c[l.PRERELEASELOOSE]}?${c[l.BUILD]}?`);m("LOOSE",`^${c[l.LOOSEPLAIN]}$`);m("GTLT","((?:<|>)?=?)");m("XRANGEIDENTIFIERLOOSE",`${c[l.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`);m("XRANGEIDENTIFIER",`${c[l.NUMERICIDENTIFIER]}|x|X|\\*`);m("XRANGEPLAIN",`[v=\\s]*(${c[l.XRANGEIDENTIFIER]})(?:\\.(${c[l.XRANGEIDENTIFIER]})(?:\\.(${c[l.XRANGEIDENTIFIER]})(?:${c[l.PRERELEASE]})?${c[l.BUILD]}?)?)?`);m("XRANGEPLAINLOOSE",`[v=\\s]*(${c[l.XRANGEIDENTIFIERLOOSE]})(?:\\.(${c[l.XRANGEIDENTIFIERLOOSE]})(?:\\.(${c[l.XRANGEIDENTIFIERLOOSE]})(?:${c[l.PRERELEASELOOSE]})?${c[l.BUILD]}?)?)?`);m("XRANGE",`^${c[l.GTLT]}\\s*${c[l.XRANGEPLAIN]}$`);m("XRANGELOOSE",`^${c[l.GTLT]}\\s*${c[l.XRANGEPLAINLOOSE]}$`);m("COERCEPLAIN",`(^|[^\\d])(\\d{1,${ee}})(?:\\.(\\d{1,${ee}}))?(?:\\.(\\d{1,${ee}}))?`);m("COERCE",`${c[l.COERCEPLAIN]}(?:$|[^\\d])`);m("COERCEFULL",c[l.COERCEPLAIN]+`(?:${c[l.PRERELEASE]})?(?:${c[l.BUILD]})?(?:$|[^\\d])`);m("COERCERTL",c[l.COERCE],!0);m("COERCERTLFULL",c[l.COERCEFULL],!0);m("LONETILDE","(?:~>?)");m("TILDETRIM",`(\\s*)${c[l.LONETILDE]}\\s+`,!0);T.tildeTrimReplace="$1~";m("TILDE",`^${c[l.LONETILDE]}${c[l.XRANGEPLAIN]}$`);m("TILDELOOSE",`^${c[l.LONETILDE]}${c[l.XRANGEPLAINLOOSE]}$`);m("LONECARET","(?:\\^)");m("CARETTRIM",`(\\s*)${c[l.LONECARET]}\\s+`,!0);T.caretTrimReplace="$1^";m("CARET",`^${c[l.LONECARET]}${c[l.XRANGEPLAIN]}$`);m("CARETLOOSE",`^${c[l.LONECARET]}${c[l.XRANGEPLAINLOOSE]}$`);m("COMPARATORLOOSE",`^${c[l.GTLT]}\\s*(${c[l.LOOSEPLAIN]})$|^$`);m("COMPARATOR",`^${c[l.GTLT]}\\s*(${c[l.FULLPLAIN]})$|^$`);m("COMPARATORTRIM",`(\\s*)${c[l.GTLT]}\\s*(${c[l.LOOSEPLAIN]}|${c[l.XRANGEPLAIN]})`,!0);T.comparatorTrimReplace="$1$2$3";m("HYPHENRANGE",`^\\s*(${c[l.XRANGEPLAIN]})\\s+-\\s+(${c[l.XRANGEPLAIN]})\\s*$`);m("HYPHENRANGELOOSE",`^\\s*(${c[l.XRANGEPLAINLOOSE]})\\s+-\\s+(${c[l.XRANGEPLAINLOOSE]})\\s*$`);m("STAR","(<|>)?=?\\s*\\*");m("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$");m("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")});var b=p((Ai,Oe)=>{"use strict";var bt=Object.freeze({loose:!0}),Ut=Object.freeze({}),Vt=t=>t?typeof t!="object"?bt:t:Ut;Oe.exports=Vt});var te=p((wi,we)=>{"use strict";var Te=/^[0-9]+$/,Ae=(t,e)=>{if(typeof t=="number"&&typeof e=="number")return t===e?0:t<e?-1:1;let r=Te.test(t),s=Te.test(e);return r&&s&&(t=+t,e=+e),t===e?0:r&&!s?-1:s&&!r?1:t<e?-1:1},Xt=(t,e)=>Ae(e,t);we.exports={compareIdentifiers:Ae,rcompareIdentifiers:Xt}});var I=p((qi,ve)=>{"use strict";var U=x(),{MAX_LENGTH:qe,MAX_SAFE_INTEGER:V}=P(),{safeRe:X,t:k}=q(),kt=b(),{compareIdentifiers:se}=te(),ne=class t{constructor(e,r){if(r=kt(r),e instanceof t){if(e.loose===!!r.loose&&e.includePrerelease===!!r.includePrerelease)return e;e=e.version}else if(typeof e!="string")throw new TypeError(`Invalid version. Must be a string. Got type "${typeof e}".`);if(e.length>qe)throw new TypeError(`version is longer than ${qe} characters`);U("SemVer",e,r),this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease;let s=e.trim().match(r.loose?X[k.LOOSE]:X[k.FULL]);if(!s)throw new TypeError(`Invalid Version: ${e}`);if(this.raw=e,this.major=+s[1],this.minor=+s[2],this.patch=+s[3],this.major>V||this.major<0)throw new TypeError("Invalid major version");if(this.minor>V||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>V||this.patch<0)throw new TypeError("Invalid patch version");s[4]?this.prerelease=s[4].split(".").map(n=>{if(/^[0-9]+$/.test(n)){let i=+n;if(i>=0&&i<V)return i}return n}):this.prerelease=[],this.build=s[5]?s[5].split("."):[],this.format()}format(){return this.version=`${this.major}.${this.minor}.${this.patch}`,this.prerelease.length&&(this.version+=`-${this.prerelease.join(".")}`),this.version}toString(){return this.version}compare(e){if(U("SemVer.compare",this.version,this.options,e),!(e instanceof t)){if(typeof e=="string"&&e===this.version)return 0;e=new t(e,this.options)}return e.version===this.version?0:this.compareMain(e)||this.comparePre(e)}compareMain(e){return e instanceof t||(e=new t(e,this.options)),this.major<e.major?-1:this.major>e.major?1:this.minor<e.minor?-1:this.minor>e.minor?1:this.patch<e.patch?-1:this.patch>e.patch?1:0}comparePre(e){if(e instanceof t||(e=new t(e,this.options)),this.prerelease.length&&!e.prerelease.length)return-1;if(!this.prerelease.length&&e.prerelease.length)return 1;if(!this.prerelease.length&&!e.prerelease.length)return 0;let r=0;do{let s=this.prerelease[r],n=e.prerelease[r];if(U("prerelease compare",r,s,n),s===void 0&&n===void 0)return 0;if(n===void 0)return 1;if(s===void 0)return-1;if(s===n)continue;return se(s,n)}while(++r)}compareBuild(e){e instanceof t||(e=new t(e,this.options));let r=0;do{let s=this.build[r],n=e.build[r];if(U("build compare",r,s,n),s===void 0&&n===void 0)return 0;if(n===void 0)return 1;if(s===void 0)return-1;if(s===n)continue;return se(s,n)}while(++r)}inc(e,r,s){if(e.startsWith("pre")){if(!r&&s===!1)throw new Error("invalid increment argument: identifier is empty");if(r){let n=`-${r}`.match(this.options.loose?X[k.PRERELEASELOOSE]:X[k.PRERELEASE]);if(!n||n[1]!==r)throw new Error(`invalid identifier: ${r}`)}}switch(e){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",r,s);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",r,s);break;case"prepatch":this.prerelease.length=0,this.inc("patch",r,s),this.inc("pre",r,s);break;case"prerelease":this.prerelease.length===0&&this.inc("patch",r,s),this.inc("pre",r,s);break;case"release":if(this.prerelease.length===0)throw new Error(`version ${this.raw} is not a prerelease`);this.prerelease.length=0;break;case"major":(this.minor!==0||this.patch!==0||this.prerelease.length===0)&&this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":(this.patch!==0||this.prerelease.length===0)&&this.minor++,this.patch=0,this.prerelease=[];break;case"patch":this.prerelease.length===0&&this.patch++,this.prerelease=[];break;case"pre":{let n=Number(s)?1:0;if(this.prerelease.length===0)this.prerelease=[n];else{let i=this.prerelease.length;for(;--i>=0;)typeof this.prerelease[i]=="number"&&(this.prerelease[i]++,i=-2);if(i===-1){if(r===this.prerelease.join(".")&&s===!1)throw new Error("invalid increment argument: identifier already exists");this.prerelease.push(n)}}if(r){let i=[r,n];s===!1&&(i=[r]),se(this.prerelease[0],r)===0?isNaN(this.prerelease[1])&&(this.prerelease=i):this.prerelease=i}break}default:throw new Error(`invalid increment argument: ${e}`)}return this.raw=this.format(),this.build.length&&(this.raw+=`+${this.build.join(".")}`),this}};ve.exports=ne});var w=p((vi,xe)=>{"use strict";var Pe=I(),_t=(t,e,r=!1)=>{if(t instanceof Pe)return t;try{return new Pe(t,e)}catch(s){if(!r)return null;throw s}};xe.exports=_t});var De=p((Pi,Ce)=>{"use strict";var Ht=w(),Wt=(t,e)=>{let r=Ht(t,e);return r?r.version:null};Ce.exports=Wt});var je=p((xi,ye)=>{"use strict";var Mt=w(),Yt=(t,e)=>{let r=Mt(t.trim().replace(/^[=v]+/,""),e);return r?r.version:null};ye.exports=Yt});var be=p((Ci,Ge)=>{"use strict";var Fe=I(),Bt=(t,e,r,s,n)=>{typeof r=="string"&&(n=s,s=r,r=void 0);try{return new Fe(t instanceof Fe?t.version:t,r).inc(e,s,n).version}catch(i){return null}};Ge.exports=Bt});var Xe=p((Di,Ve)=>{"use strict";var Ue=w(),zt=(t,e)=>{let r=Ue(t,null,!0),s=Ue(e,null,!0),n=r.compare(s);if(n===0)return null;let i=n>0,o=i?r:s,a=i?s:r,u=!!o.prerelease.length;if(!!a.prerelease.length&&!u){if(!a.patch&&!a.minor)return"major";if(a.compareMain(o)===0)return a.minor&&!a.patch?"minor":"patch"}let $=u?"pre":"";return r.major!==s.major?$+"major":r.minor!==s.minor?$+"minor":r.patch!==s.patch?$+"patch":"prerelease"};Ve.exports=zt});var _e=p((yi,ke)=>{"use strict";var Kt=I(),Zt=(t,e)=>new Kt(t,e).major;ke.exports=Zt});var We=p((ji,He)=>{"use strict";var Jt=I(),Qt=(t,e)=>new Jt(t,e).minor;He.exports=Qt});var Ye=p((Fi,Me)=>{"use strict";var es=I(),rs=(t,e)=>new es(t,e).patch;Me.exports=rs});var ze=p((Gi,Be)=>{"use strict";var ts=w(),ss=(t,e)=>{let r=ts(t,e);return r&&r.prerelease.length?r.prerelease:null};Be.exports=ss});var S=p((bi,Ze)=>{"use strict";var Ke=I(),ns=(t,e,r)=>new Ke(t,r).compare(new Ke(e,r));Ze.exports=ns});var Qe=p((Ui,Je)=>{"use strict";var is=S(),os=(t,e,r)=>is(e,t,r);Je.exports=os});var rr=p((Vi,er)=>{"use strict";var as=S(),cs=(t,e)=>as(t,e,!0);er.exports=cs});var _=p((Xi,sr)=>{"use strict";var tr=I(),ls=(t,e,r)=>{let s=new tr(t,r),n=new tr(e,r);return s.compare(n)||s.compareBuild(n)};sr.exports=ls});var ir=p((ki,nr)=>{"use strict";var us=_(),fs=(t,e)=>t.sort((r,s)=>us(r,s,e));nr.exports=fs});var ar=p((_i,or)=>{"use strict";var hs=_(),Es=(t,e)=>t.sort((r,s)=>hs(s,r,e));or.exports=Es});var C=p((Hi,cr)=>{"use strict";var ps=S(),ms=(t,e,r)=>ps(t,e,r)>0;cr.exports=ms});var H=p((Wi,lr)=>{"use strict";var $s=S(),Rs=(t,e,r)=>$s(t,e,r)<0;lr.exports=Rs});var ie=p((Mi,ur)=>{"use strict";var ds=S(),Is=(t,e,r)=>ds(t,e,r)===0;ur.exports=Is});var oe=p((Yi,fr)=>{"use strict";var gs=S(),Ls=(t,e,r)=>gs(t,e,r)!==0;fr.exports=Ls});var W=p((Bi,hr)=>{"use strict";var Ns=S(),Ss=(t,e,r)=>Ns(t,e,r)>=0;hr.exports=Ss});var M=p((zi,Er)=>{"use strict";var Os=S(),Ts=(t,e,r)=>Os(t,e,r)<=0;Er.exports=Ts});var ae=p((Ki,pr)=>{"use strict";var As=ie(),ws=oe(),qs=C(),vs=W(),Ps=H(),xs=M(),Cs=(t,e,r,s)=>{switch(e){case"===":return typeof t=="object"&&(t=t.version),typeof r=="object"&&(r=r.version),t===r;case"!==":return typeof t=="object"&&(t=t.version),typeof r=="object"&&(r=r.version),t!==r;case"":case"=":case"==":return As(t,r,s);case"!=":return ws(t,r,s);case">":return qs(t,r,s);case">=":return vs(t,r,s);case"<":return Ps(t,r,s);case"<=":return xs(t,r,s);default:throw new TypeError(`Invalid operator: ${e}`)}};pr.exports=Cs});var $r=p((Zi,mr)=>{"use strict";var Ds=I(),ys=w(),{safeRe:Y,t:B}=q(),js=(t,e)=>{if(t instanceof Ds)return t;if(typeof t=="number"&&(t=String(t)),typeof t!="string")return null;e=e||{};let r=null;if(!e.rtl)r=t.match(e.includePrerelease?Y[B.COERCEFULL]:Y[B.COERCE]);else{let u=e.includePrerelease?Y[B.COERCERTLFULL]:Y[B.COERCERTL],f;for(;(f=u.exec(t))&&(!r||r.index+r[0].length!==t.length);)(!r||f.index+f[0].length!==r.index+r[0].length)&&(r=f),u.lastIndex=f.index+f[1].length+f[2].length;u.lastIndex=-1}if(r===null)return null;let s=r[2],n=r[3]||"0",i=r[4]||"0",o=e.includePrerelease&&r[5]?`-${r[5]}`:"",a=e.includePrerelease&&r[6]?`+${r[6]}`:"";return ys(`${s}.${n}.${i}${o}${a}`,e)};mr.exports=js});var dr=p((Ji,Rr)=>{"use strict";var ce=class{constructor(){this.max=1e3,this.map=new Map}get(e){let r=this.map.get(e);if(r!==void 0)return this.map.delete(e),this.map.set(e,r),r}delete(e){return this.map.delete(e)}set(e,r){if(!this.delete(e)&&r!==void 0){if(this.map.size>=this.max){let n=this.map.keys().next().value;this.delete(n)}this.map.set(e,r)}return this}};Rr.exports=ce});var O=p((Qi,Nr)=>{"use strict";var Fs=/\s+/g,le=class t{constructor(e,r){if(r=bs(r),e instanceof t)return e.loose===!!r.loose&&e.includePrerelease===!!r.includePrerelease?e:new t(e.raw,r);if(e instanceof ue)return this.raw=e.value,this.set=[[e]],this.formatted=void 0,this;if(this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease,this.raw=e.trim().replace(Fs," "),this.set=this.raw.split("||").map(s=>this.parseRange(s.trim())).filter(s=>s.length),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${this.raw}`);if(this.set.length>1){let s=this.set[0];if(this.set=this.set.filter(n=>!gr(n[0])),this.set.length===0)this.set=[s];else if(this.set.length>1){for(let n of this.set)if(n.length===1&&Ws(n[0])){this.set=[n];break}}}this.formatted=void 0}get range(){if(this.formatted===void 0){this.formatted="";for(let e=0;e<this.set.length;e++){e>0&&(this.formatted+="||");let r=this.set[e];for(let s=0;s<r.length;s++)s>0&&(this.formatted+=" "),this.formatted+=r[s].toString().trim()}}return this.formatted}format(){return this.range}toString(){return this.range}parseRange(e){let s=((this.options.includePrerelease&&_s)|(this.options.loose&&Hs))+":"+e,n=Ir.get(s);if(n)return n;let i=this.options.loose,o=i?L[g.HYPHENRANGELOOSE]:L[g.HYPHENRANGE];e=e.replace(o,rn(this.options.includePrerelease)),R("hyphen replace",e),e=e.replace(L[g.COMPARATORTRIM],Vs),R("comparator trim",e),e=e.replace(L[g.TILDETRIM],Xs),R("tilde trim",e),e=e.replace(L[g.CARETTRIM],ks),R("caret trim",e);let a=e.split(" ").map(h=>Ms(h,this.options)).join(" ").split(/\s+/).map(h=>en(h,this.options));i&&(a=a.filter(h=>(R("loose invalid filter",h,this.options),!!h.match(L[g.COMPARATORLOOSE])))),R("range list",a);let u=new Map,f=a.map(h=>new ue(h,this.options));for(let h of f){if(gr(h))return[h];u.set(h.value,h)}u.size>1&&u.has("")&&u.delete("");let $=[...u.values()];return Ir.set(s,$),$}intersects(e,r){if(!(e instanceof t))throw new TypeError("a Range is required");return this.set.some(s=>Lr(s,r)&&e.set.some(n=>Lr(n,r)&&s.every(i=>n.every(o=>i.intersects(o,r)))))}test(e){if(!e)return!1;if(typeof e=="string")try{e=new Us(e,this.options)}catch(r){return!1}for(let r=0;r<this.set.length;r++)if(tn(this.set[r],e,this.options))return!0;return!1}};Nr.exports=le;var Gs=dr(),Ir=new Gs,bs=b(),ue=D(),R=x(),Us=I(),{safeRe:L,t:g,comparatorTrimReplace:Vs,tildeTrimReplace:Xs,caretTrimReplace:ks}=q(),{FLAG_INCLUDE_PRERELEASE:_s,FLAG_LOOSE:Hs}=P(),gr=t=>t.value==="<0.0.0-0",Ws=t=>t.value==="",Lr=(t,e)=>{let r=!0,s=t.slice(),n=s.pop();for(;r&&s.length;)r=s.every(i=>n.intersects(i,e)),n=s.pop();return r},Ms=(t,e)=>(t=t.replace(L[g.BUILD],""),R("comp",t,e),t=zs(t,e),R("caret",t),t=Ys(t,e),R("tildes",t),t=Zs(t,e),R("xrange",t),t=Qs(t,e),R("stars",t),t),N=t=>!t||t.toLowerCase()==="x"||t==="*",Ys=(t,e)=>t.trim().split(/\s+/).map(r=>Bs(r,e)).join(" "),Bs=(t,e)=>{let r=e.loose?L[g.TILDELOOSE]:L[g.TILDE];return t.replace(r,(s,n,i,o,a)=>{R("tilde",t,s,n,i,o,a);let u;return N(n)?u="":N(i)?u=`>=${n}.0.0 <${+n+1}.0.0-0`:N(o)?u=`>=${n}.${i}.0 <${n}.${+i+1}.0-0`:a?(R("replaceTilde pr",a),u=`>=${n}.${i}.${o}-${a} <${n}.${+i+1}.0-0`):u=`>=${n}.${i}.${o} <${n}.${+i+1}.0-0`,R("tilde return",u),u})},zs=(t,e)=>t.trim().split(/\s+/).map(r=>Ks(r,e)).join(" "),Ks=(t,e)=>{R("caret",t,e);let r=e.loose?L[g.CARETLOOSE]:L[g.CARET],s=e.includePrerelease?"-0":"";return t.replace(r,(n,i,o,a,u)=>{R("caret",t,n,i,o,a,u);let f;return N(i)?f="":N(o)?f=`>=${i}.0.0${s} <${+i+1}.0.0-0`:N(a)?i==="0"?f=`>=${i}.${o}.0${s} <${i}.${+o+1}.0-0`:f=`>=${i}.${o}.0${s} <${+i+1}.0.0-0`:u?(R("replaceCaret pr",u),i==="0"?o==="0"?f=`>=${i}.${o}.${a}-${u} <${i}.${o}.${+a+1}-0`:f=`>=${i}.${o}.${a}-${u} <${i}.${+o+1}.0-0`:f=`>=${i}.${o}.${a}-${u} <${+i+1}.0.0-0`):(R("no pr"),i==="0"?o==="0"?f=`>=${i}.${o}.${a}${s} <${i}.${o}.${+a+1}-0`:f=`>=${i}.${o}.${a}${s} <${i}.${+o+1}.0-0`:f=`>=${i}.${o}.${a} <${+i+1}.0.0-0`),R("caret return",f),f})},Zs=(t,e)=>(R("replaceXRanges",t,e),t.split(/\s+/).map(r=>Js(r,e)).join(" ")),Js=(t,e)=>{t=t.trim();let r=e.loose?L[g.XRANGELOOSE]:L[g.XRANGE];return t.replace(r,(s,n,i,o,a,u)=>{R("xRange",t,s,n,i,o,a,u);let f=N(i),$=f||N(o),h=$||N(a),d=h;return n==="="&&d&&(n=""),u=e.includePrerelease?"-0":"",f?n===">"||n==="<"?s="<0.0.0-0":s="*":n&&d?($&&(o=0),a=0,n===">"?(n=">=",$?(i=+i+1,o=0,a=0):(o=+o+1,a=0)):n==="<="&&(n="<",$?i=+i+1:o=+o+1),n==="<"&&(u="-0"),s=`${n+i}.${o}.${a}${u}`):$?s=`>=${i}.0.0${u} <${+i+1}.0.0-0`:h&&(s=`>=${i}.${o}.0${u} <${i}.${+o+1}.0-0`),R("xRange return",s),s})},Qs=(t,e)=>(R("replaceStars",t,e),t.trim().replace(L[g.STAR],"")),en=(t,e)=>(R("replaceGTE0",t,e),t.trim().replace(L[e.includePrerelease?g.GTE0PRE:g.GTE0],"")),rn=t=>(e,r,s,n,i,o,a,u,f,$,h,d)=>(N(s)?r="":N(n)?r=`>=${s}.0.0${t?"-0":""}`:N(i)?r=`>=${s}.${n}.0${t?"-0":""}`:o?r=`>=${r}`:r=`>=${r}${t?"-0":""}`,N(f)?u="":N($)?u=`<${+f+1}.0.0-0`:N(h)?u=`<${f}.${+$+1}.0-0`:d?u=`<=${f}.${$}.${h}-${d}`:t?u=`<${f}.${$}.${+h+1}-0`:u=`<=${u}`,`${r} ${u}`.trim()),tn=(t,e,r)=>{for(let s=0;s<t.length;s++)if(!t[s].test(e))return!1;if(e.prerelease.length&&!r.includePrerelease){for(let s=0;s<t.length;s++)if(R(t[s].semver),t[s].semver!==ue.ANY&&t[s].semver.prerelease.length>0){let n=t[s].semver;if(n.major===e.major&&n.minor===e.minor&&n.patch===e.patch)return!0}return!1}return!0}});var D=p((eo,qr)=>{"use strict";var y=Symbol("SemVer ANY"),Ee=class t{static get ANY(){return y}constructor(e,r){if(r=Sr(r),e instanceof t){if(e.loose===!!r.loose)return e;e=e.value}e=e.trim().split(/\s+/).join(" "),he("comparator",e,r),this.options=r,this.loose=!!r.loose,this.parse(e),this.semver===y?this.value="":this.value=this.operator+this.semver.version,he("comp",this)}parse(e){let r=this.options.loose?Or[Tr.COMPARATORLOOSE]:Or[Tr.COMPARATOR],s=e.match(r);if(!s)throw new TypeError(`Invalid comparator: ${e}`);this.operator=s[1]!==void 0?s[1]:"",this.operator==="="&&(this.operator=""),s[2]?this.semver=new Ar(s[2],this.options.loose):this.semver=y}toString(){return this.value}test(e){if(he("Comparator.test",e,this.options.loose),this.semver===y||e===y)return!0;if(typeof e=="string")try{e=new Ar(e,this.options)}catch(r){return!1}return fe(e,this.operator,this.semver,this.options)}intersects(e,r){if(!(e instanceof t))throw new TypeError("a Comparator is required");return this.operator===""?this.value===""?!0:new wr(e.value,r).test(this.value):e.operator===""?e.value===""?!0:new wr(this.value,r).test(e.semver):(r=Sr(r),r.includePrerelease&&(this.value==="<0.0.0-0"||e.value==="<0.0.0-0")||!r.includePrerelease&&(this.value.startsWith("<0.0.0")||e.value.startsWith("<0.0.0"))?!1:!!(this.operator.startsWith(">")&&e.operator.startsWith(">")||this.operator.startsWith("<")&&e.operator.startsWith("<")||this.semver.version===e.semver.version&&this.operator.includes("=")&&e.operator.includes("=")||fe(this.semver,"<",e.semver,r)&&this.operator.startsWith(">")&&e.operator.startsWith("<")||fe(this.semver,">",e.semver,r)&&this.operator.startsWith("<")&&e.operator.startsWith(">")))}};qr.exports=Ee;var Sr=b(),{safeRe:Or,t:Tr}=q(),fe=ae(),he=x(),Ar=I(),wr=O()});var j=p((ro,vr)=>{"use strict";var sn=O(),nn=(t,e,r)=>{try{e=new sn(e,r)}catch(s){return!1}return e.test(t)};vr.exports=nn});var xr=p((to,Pr)=>{"use strict";var on=O(),an=(t,e)=>new on(t,e).set.map(r=>r.map(s=>s.value).join(" ").trim().split(" "));Pr.exports=an});var Dr=p((so,Cr)=>{"use strict";var cn=I(),ln=O(),un=(t,e,r)=>{let s=null,n=null,i=null;try{i=new ln(e,r)}catch(o){return null}return t.forEach(o=>{i.test(o)&&(!s||n.compare(o)===-1)&&(s=o,n=new cn(s,r))}),s};Cr.exports=un});var jr=p((no,yr)=>{"use strict";var fn=I(),hn=O(),En=(t,e,r)=>{let s=null,n=null,i=null;try{i=new hn(e,r)}catch(o){return null}return t.forEach(o=>{i.test(o)&&(!s||n.compare(o)===1)&&(s=o,n=new fn(s,r))}),s};yr.exports=En});var br=p((io,Gr)=>{"use strict";var pe=I(),pn=O(),Fr=C(),mn=(t,e)=>{t=new pn(t,e);let r=new pe("0.0.0");if(t.test(r)||(r=new pe("0.0.0-0"),t.test(r)))return r;r=null;for(let s=0;s<t.set.length;++s){let n=t.set[s],i=null;n.forEach(o=>{let a=new pe(o.semver.version);switch(o.operator){case">":a.prerelease.length===0?a.patch++:a.prerelease.push(0),a.raw=a.format();case"":case">=":(!i||Fr(a,i))&&(i=a);break;case"<":case"<=":break;default:throw new Error(`Unexpected operation: ${o.operator}`)}}),i&&(!r||Fr(r,i))&&(r=i)}return r&&t.test(r)?r:null};Gr.exports=mn});var Vr=p((oo,Ur)=>{"use strict";var $n=O(),Rn=(t,e)=>{try{return new $n(t,e).range||"*"}catch(r){return null}};Ur.exports=Rn});var z=p((ao,Hr)=>{"use strict";var dn=I(),_r=D(),{ANY:In}=_r,gn=O(),Ln=j(),Xr=C(),kr=H(),Nn=M(),Sn=W(),On=(t,e,r,s)=>{t=new dn(t,s),e=new gn(e,s);let n,i,o,a,u;switch(r){case">":n=Xr,i=Nn,o=kr,a=">",u=">=";break;case"<":n=kr,i=Sn,o=Xr,a="<",u="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(Ln(t,e,s))return!1;for(let f=0;f<e.set.length;++f){let $=e.set[f],h=null,d=null;if($.forEach(E=>{E.semver===In&&(E=new _r(">=0.0.0")),h=h||E,d=d||E,n(E.semver,h.semver,s)?h=E:o(E.semver,d.semver,s)&&(d=E)}),h.operator===a||h.operator===u||(!d.operator||d.operator===a)&&i(t,d.semver))return!1;if(d.operator===u&&o(t,d.semver))return!1}return!0};Hr.exports=On});var Mr=p((co,Wr)=>{"use strict";var Tn=z(),An=(t,e,r)=>Tn(t,e,">",r);Wr.exports=An});var Br=p((lo,Yr)=>{"use strict";var wn=z(),qn=(t,e,r)=>wn(t,e,"<",r);Yr.exports=qn});var Zr=p((uo,Kr)=>{"use strict";var zr=O(),vn=(t,e,r)=>(t=new zr(t,r),e=new zr(e,r),t.intersects(e,r));Kr.exports=vn});var Qr=p((fo,Jr)=>{"use strict";var Pn=j(),xn=S();Jr.exports=(t,e,r)=>{let s=[],n=null,i=null,o=t.sort(($,h)=>xn($,h,r));for(let $ of o)Pn($,e,r)?(i=$,n||(n=$)):(i&&s.push([n,i]),i=null,n=null);n&&s.push([n,null]);let a=[];for(let[$,h]of s)$===h?a.push($):!h&&$===o[0]?a.push("*"):h?$===o[0]?a.push(`<=${h}`):a.push(`${$} - ${h}`):a.push(`>=${$}`);let u=a.join(" || "),f=typeof e.raw=="string"?e.raw:String(e);return u.length<f.length?u:e}});var it=p((ho,nt)=>{"use strict";var et=O(),$e=D(),{ANY:me}=$e,F=j(),Re=S(),Cn=(t,e,r={})=>{if(t===e)return!0;t=new et(t,r),e=new et(e,r);let s=!1;e:for(let n of t.set){for(let i of e.set){let o=yn(n,i,r);if(s=s||o!==null,o)continue e}if(s)return!1}return!0},Dn=[new $e(">=0.0.0-0")],rt=[new $e(">=0.0.0")],yn=(t,e,r)=>{if(t===e)return!0;if(t.length===1&&t[0].semver===me){if(e.length===1&&e[0].semver===me)return!0;r.includePrerelease?t=Dn:t=rt}if(e.length===1&&e[0].semver===me){if(r.includePrerelease)return!0;e=rt}let s=new Set,n,i;for(let E of t)E.operator===">"||E.operator===">="?n=tt(n,E,r):E.operator==="<"||E.operator==="<="?i=st(i,E,r):s.add(E.semver);if(s.size>1)return null;let o;if(n&&i){if(o=Re(n.semver,i.semver,r),o>0)return null;if(o===0&&(n.operator!==">="||i.operator!=="<="))return null}for(let E of s){if(n&&!F(E,String(n),r)||i&&!F(E,String(i),r))return null;for(let pt of e)if(!F(E,String(pt),r))return!1;return!0}let a,u,f,$,h=i&&!r.includePrerelease&&i.semver.prerelease.length?i.semver:!1,d=n&&!r.includePrerelease&&n.semver.prerelease.length?n.semver:!1;h&&h.prerelease.length===1&&i.operator==="<"&&h.prerelease[0]===0&&(h=!1);for(let E of e){if($=$||E.operator===">"||E.operator===">=",f=f||E.operator==="<"||E.operator==="<=",n){if(d&&E.semver.prerelease&&E.semver.prerelease.length&&E.semver.major===d.major&&E.semver.minor===d.minor&&E.semver.patch===d.patch&&(d=!1),E.operator===">"||E.operator===">="){if(a=tt(n,E,r),a===E&&a!==n)return!1}else if(n.operator===">="&&!F(n.semver,String(E),r))return!1}if(i){if(h&&E.semver.prerelease&&E.semver.prerelease.length&&E.semver.major===h.major&&E.semver.minor===h.minor&&E.semver.patch===h.patch&&(h=!1),E.operator==="<"||E.operator==="<="){if(u=st(i,E,r),u===E&&u!==i)return!1}else if(i.operator==="<="&&!F(i.semver,String(E),r))return!1}if(!E.operator&&(i||n)&&o!==0)return!1}return!(n&&f&&!i&&o!==0||i&&$&&!n&&o!==0||d||h)},tt=(t,e,r)=>{if(!t)return e;let s=Re(t.semver,e.semver,r);return s>0?t:s<0||e.operator===">"&&t.operator===">="?e:t},st=(t,e,r)=>{if(!t)return e;let s=Re(t.semver,e.semver,r);return s<0?t:s>0||e.operator==="<"&&t.operator==="<="?e:t};nt.exports=Cn});var lt=p((Eo,ct)=>{"use strict";var de=q(),ot=P(),jn=I(),at=te(),Fn=w(),Gn=De(),bn=je(),Un=be(),Vn=Xe(),Xn=_e(),kn=We(),_n=Ye(),Hn=ze(),Wn=S(),Mn=Qe(),Yn=rr(),Bn=_(),zn=ir(),Kn=ar(),Zn=C(),Jn=H(),Qn=ie(),ei=oe(),ri=W(),ti=M(),si=ae(),ni=$r(),ii=D(),oi=O(),ai=j(),ci=xr(),li=Dr(),ui=jr(),fi=br(),hi=Vr(),Ei=z(),pi=Mr(),mi=Br(),$i=Zr(),Ri=Qr(),di=it();ct.exports={parse:Fn,valid:Gn,clean:bn,inc:Un,diff:Vn,major:Xn,minor:kn,patch:_n,prerelease:Hn,compare:Wn,rcompare:Mn,compareLoose:Yn,compareBuild:Bn,sort:zn,rsort:Kn,gt:Zn,lt:Jn,eq:Qn,neq:ei,gte:ri,lte:ti,cmp:si,coerce:ni,Comparator:ii,Range:oi,satisfies:ai,toComparators:ci,maxSatisfying:li,minSatisfying:ui,minVersion:fi,validRange:hi,outside:Ei,gtr:pi,ltr:mi,intersects:$i,simplifyRange:Ri,subset:di,SemVer:jn,re:de.re,src:de.src,tokens:de.t,SEMVER_SPEC_VERSION:ot.SEMVER_SPEC_VERSION,RELEASE_TYPES:ot.RELEASE_TYPES,compareIdentifiers:at.compareIdentifiers,rcompareIdentifiers:at.rcompareIdentifiers}});var Ni={};gt(Ni,{ngAdd:()=>Li});module.exports=Nt(Ni);var Q=require("@angular-devkit/schematics/tasks");var J=require("@angular-devkit/schematics"),A=Lt(lt());var K=t=>JSON.stringify(t,null,2),Z=(t,e,r)=>{t.exists(e)?t.overwrite(e,r):t.create(e,r)};function Ie(t,e){try{return JSON.parse(e.read(t).toString())}catch(r){throw new J.SchematicsException(`Error when parsing ${t}: ${r.message}`)}}var ut=(t,e,r)=>{var n,i;let s=t.exists("package.json")&&Ie("package.json",t);if(s===void 0)throw new J.SchematicsException("Could not locate package.json");(n=s.devDependencies)!=null||(s.devDependencies={}),(i=s.dependencies)!=null||(s.dependencies={}),Object.keys(e).forEach(o=>{let a=e[o],u=a.dev?s.devDependencies:s.dependencies,f=u[o];if(f)try{(0,A.intersects)(f,a.version)||r.logger.warn(`\u26A0\uFE0F The ${o} devDependency specified in your package.json (${f}) does not fulfill AngularFire's dependency (${a.version})`)}catch($){f!==a.version&&r.logger.warn(`\u26A0\uFE0F The ${o} devDependency specified in your package.json (${f}) does not fulfill AngularFire's dependency (${a.version})`)}else u[o]=a.version}),Z(t,"package.json",K(s))},v="^12.18.0",ft=(t,e)=>{var i;if(!t.exists("package.json"))throw new J.SchematicsException("Could not locate package.json");let r=Ie("package.json",t),s=["dependencies","devDependencies"].filter(o=>{var a;return typeof((a=r[o])==null?void 0:a.firebase)=="string"});if(s.length===0)return(i=r.dependencies)!=null||(r.dependencies={}),r.dependencies.firebase=v,e.logger.info(`Added firebase ${v} to your package.json.`),Z(t,"package.json",K(r)),!0;let n=!1;for(let o of s){let a=r[o].firebase,u;try{u=(0,A.subset)(a,v)}catch(f){e.logger.warn(`\u26A0\uFE0F The firebase version in your package.json (${a}) is not a semver range, so it was left as-is; make sure it resolves inside ${v}, the range @angular/fire requires; a version outside it can leave the install with two copies of the firebase SDK.`);continue}u||(r[o].firebase=v,e.logger.info(`Updated the firebase version in your package.json from ${a} to ${v}, the range @angular/fire requires; a workspace range outside it can leave the install with a second copy of the firebase SDK, which fails at runtime.`),n=!0)}return n&&Z(t,"package.json",K(r)),n},Ii="21.0.0-rc.0-canary.97f61a4",ht=(t,e,r=Ii)=>{if(!t.exists("package.json"))return;let s=Ie("package.json",t),n=["dependencies","devDependencies"].find(o=>{var a;return typeof((a=s[o])==null?void 0:a["@angular/fire"])=="string"});if(!n)return;let i=s[n]["@angular/fire"];if(i.startsWith("^")||i.startsWith("~")){if(!(0,A.valid)(r)){e.logger.warn("Could not determine the installed @angular/fire version; leaving the declared version range as-is.");return}(0,A.prerelease)(r)&&(0,A.satisfies)(r,i,{includePrerelease:!0})&&(s[n]["@angular/fire"]=r,Z(t,"package.json",K(s)),e.logger.info(`Pinned @angular/fire to the exact version ${r} \u2014 a prerelease range like ${i} also matches unreviewed canary builds, so a later install could silently change versions.`))}};var Et={};var Li=t=>(e,r)=>{ut(e,Et,r),ft(e,r),ht(e,r);let s=r.addTask(new Q.NodePackageInstallTask);return r.addTask(new Q.RunSchematicTask("ng-add-setup-project",t),[s]),e};0&&(module.exports={ngAdd});
|
|
1
|
+
var mt=Object.create;var G=Object.defineProperty;var $t=Object.getOwnPropertyDescriptor;var Rt=Object.getOwnPropertyNames;var dt=Object.getPrototypeOf,It=Object.prototype.hasOwnProperty;var p=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),gt=(t,e)=>{for(var r in e)G(t,r,{get:e[r],enumerable:!0})},ge=(t,e,r,s)=>{if(e&&typeof e=="object"||typeof e=="function")for(let n of Rt(e))!It.call(t,n)&&n!==r&&G(t,n,{get:()=>e[n],enumerable:!(s=$t(e,n))||s.enumerable});return t};var Lt=(t,e,r)=>(r=t!=null?mt(dt(t)):{},ge(e||!t||!t.__esModule?G(r,"default",{value:t,enumerable:!0}):r,t)),Nt=t=>ge(G({},"__esModule",{value:!0}),t);var P=p((Oi,Le)=>{"use strict";var St="2.0.0",Ot=Number.MAX_SAFE_INTEGER||9007199254740991,Tt=16,At=250,wt=["major","premajor","minor","preminor","patch","prepatch","prerelease"];Le.exports={MAX_LENGTH:256,MAX_SAFE_COMPONENT_LENGTH:Tt,MAX_SAFE_BUILD_LENGTH:At,MAX_SAFE_INTEGER:Ot,RELEASE_TYPES:wt,SEMVER_SPEC_VERSION:St,FLAG_INCLUDE_PRERELEASE:1,FLAG_LOOSE:2}});var x=p((Ti,Ne)=>{"use strict";var qt=typeof process=="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?(...t)=>console.error("SEMVER",...t):()=>{};Ne.exports=qt});var q=p((T,Se)=>{"use strict";var{MAX_SAFE_COMPONENT_LENGTH:ee,MAX_SAFE_BUILD_LENGTH:vt,MAX_LENGTH:Pt}=P(),xt=x();T=Se.exports={};var Ct=T.re=[],Dt=T.safeRe=[],c=T.src=[],yt=T.safeSrc=[],l=T.t={},jt=0,re="[a-zA-Z0-9-]",Ft=[["\\s",1],["\\d",Pt],[re,vt]],Gt=t=>{for(let[e,r]of Ft)t=t.split(`${e}*`).join(`${e}{0,${r}}`).split(`${e}+`).join(`${e}{1,${r}}`);return t},m=(t,e,r)=>{let s=Gt(e),n=jt++;xt(t,n,e),l[t]=n,c[n]=e,yt[n]=s,Ct[n]=new RegExp(e,r?"g":void 0),Dt[n]=new RegExp(s,r?"g":void 0)};m("NUMERICIDENTIFIER","0|[1-9]\\d*");m("NUMERICIDENTIFIERLOOSE","\\d+");m("NONNUMERICIDENTIFIER",`\\d*[a-zA-Z-]${re}*`);m("MAINVERSION",`(${c[l.NUMERICIDENTIFIER]})\\.(${c[l.NUMERICIDENTIFIER]})\\.(${c[l.NUMERICIDENTIFIER]})`);m("MAINVERSIONLOOSE",`(${c[l.NUMERICIDENTIFIERLOOSE]})\\.(${c[l.NUMERICIDENTIFIERLOOSE]})\\.(${c[l.NUMERICIDENTIFIERLOOSE]})`);m("PRERELEASEIDENTIFIER",`(?:${c[l.NONNUMERICIDENTIFIER]}|${c[l.NUMERICIDENTIFIER]})`);m("PRERELEASEIDENTIFIERLOOSE",`(?:${c[l.NONNUMERICIDENTIFIER]}|${c[l.NUMERICIDENTIFIERLOOSE]})`);m("PRERELEASE",`(?:-(${c[l.PRERELEASEIDENTIFIER]}(?:\\.${c[l.PRERELEASEIDENTIFIER]})*))`);m("PRERELEASELOOSE",`(?:-?(${c[l.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${c[l.PRERELEASEIDENTIFIERLOOSE]})*))`);m("BUILDIDENTIFIER",`${re}+`);m("BUILD",`(?:\\+(${c[l.BUILDIDENTIFIER]}(?:\\.${c[l.BUILDIDENTIFIER]})*))`);m("FULLPLAIN",`v?${c[l.MAINVERSION]}${c[l.PRERELEASE]}?${c[l.BUILD]}?`);m("FULL",`^${c[l.FULLPLAIN]}$`);m("LOOSEPLAIN",`[v=\\s]*${c[l.MAINVERSIONLOOSE]}${c[l.PRERELEASELOOSE]}?${c[l.BUILD]}?`);m("LOOSE",`^${c[l.LOOSEPLAIN]}$`);m("GTLT","((?:<|>)?=?)");m("XRANGEIDENTIFIERLOOSE",`${c[l.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`);m("XRANGEIDENTIFIER",`${c[l.NUMERICIDENTIFIER]}|x|X|\\*`);m("XRANGEPLAIN",`[v=\\s]*(${c[l.XRANGEIDENTIFIER]})(?:\\.(${c[l.XRANGEIDENTIFIER]})(?:\\.(${c[l.XRANGEIDENTIFIER]})(?:${c[l.PRERELEASE]})?${c[l.BUILD]}?)?)?`);m("XRANGEPLAINLOOSE",`[v=\\s]*(${c[l.XRANGEIDENTIFIERLOOSE]})(?:\\.(${c[l.XRANGEIDENTIFIERLOOSE]})(?:\\.(${c[l.XRANGEIDENTIFIERLOOSE]})(?:${c[l.PRERELEASELOOSE]})?${c[l.BUILD]}?)?)?`);m("XRANGE",`^${c[l.GTLT]}\\s*${c[l.XRANGEPLAIN]}$`);m("XRANGELOOSE",`^${c[l.GTLT]}\\s*${c[l.XRANGEPLAINLOOSE]}$`);m("COERCEPLAIN",`(^|[^\\d])(\\d{1,${ee}})(?:\\.(\\d{1,${ee}}))?(?:\\.(\\d{1,${ee}}))?`);m("COERCE",`${c[l.COERCEPLAIN]}(?:$|[^\\d])`);m("COERCEFULL",c[l.COERCEPLAIN]+`(?:${c[l.PRERELEASE]})?(?:${c[l.BUILD]})?(?:$|[^\\d])`);m("COERCERTL",c[l.COERCE],!0);m("COERCERTLFULL",c[l.COERCEFULL],!0);m("LONETILDE","(?:~>?)");m("TILDETRIM",`(\\s*)${c[l.LONETILDE]}\\s+`,!0);T.tildeTrimReplace="$1~";m("TILDE",`^${c[l.LONETILDE]}${c[l.XRANGEPLAIN]}$`);m("TILDELOOSE",`^${c[l.LONETILDE]}${c[l.XRANGEPLAINLOOSE]}$`);m("LONECARET","(?:\\^)");m("CARETTRIM",`(\\s*)${c[l.LONECARET]}\\s+`,!0);T.caretTrimReplace="$1^";m("CARET",`^${c[l.LONECARET]}${c[l.XRANGEPLAIN]}$`);m("CARETLOOSE",`^${c[l.LONECARET]}${c[l.XRANGEPLAINLOOSE]}$`);m("COMPARATORLOOSE",`^${c[l.GTLT]}\\s*(${c[l.LOOSEPLAIN]})$|^$`);m("COMPARATOR",`^${c[l.GTLT]}\\s*(${c[l.FULLPLAIN]})$|^$`);m("COMPARATORTRIM",`(\\s*)${c[l.GTLT]}\\s*(${c[l.LOOSEPLAIN]}|${c[l.XRANGEPLAIN]})`,!0);T.comparatorTrimReplace="$1$2$3";m("HYPHENRANGE",`^\\s*(${c[l.XRANGEPLAIN]})\\s+-\\s+(${c[l.XRANGEPLAIN]})\\s*$`);m("HYPHENRANGELOOSE",`^\\s*(${c[l.XRANGEPLAINLOOSE]})\\s+-\\s+(${c[l.XRANGEPLAINLOOSE]})\\s*$`);m("STAR","(<|>)?=?\\s*\\*");m("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$");m("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")});var b=p((Ai,Oe)=>{"use strict";var bt=Object.freeze({loose:!0}),Ut=Object.freeze({}),Vt=t=>t?typeof t!="object"?bt:t:Ut;Oe.exports=Vt});var te=p((wi,we)=>{"use strict";var Te=/^[0-9]+$/,Ae=(t,e)=>{if(typeof t=="number"&&typeof e=="number")return t===e?0:t<e?-1:1;let r=Te.test(t),s=Te.test(e);return r&&s&&(t=+t,e=+e),t===e?0:r&&!s?-1:s&&!r?1:t<e?-1:1},Xt=(t,e)=>Ae(e,t);we.exports={compareIdentifiers:Ae,rcompareIdentifiers:Xt}});var I=p((qi,ve)=>{"use strict";var U=x(),{MAX_LENGTH:qe,MAX_SAFE_INTEGER:V}=P(),{safeRe:X,t:k}=q(),kt=b(),{compareIdentifiers:se}=te(),ne=class t{constructor(e,r){if(r=kt(r),e instanceof t){if(e.loose===!!r.loose&&e.includePrerelease===!!r.includePrerelease)return e;e=e.version}else if(typeof e!="string")throw new TypeError(`Invalid version. Must be a string. Got type "${typeof e}".`);if(e.length>qe)throw new TypeError(`version is longer than ${qe} characters`);U("SemVer",e,r),this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease;let s=e.trim().match(r.loose?X[k.LOOSE]:X[k.FULL]);if(!s)throw new TypeError(`Invalid Version: ${e}`);if(this.raw=e,this.major=+s[1],this.minor=+s[2],this.patch=+s[3],this.major>V||this.major<0)throw new TypeError("Invalid major version");if(this.minor>V||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>V||this.patch<0)throw new TypeError("Invalid patch version");s[4]?this.prerelease=s[4].split(".").map(n=>{if(/^[0-9]+$/.test(n)){let i=+n;if(i>=0&&i<V)return i}return n}):this.prerelease=[],this.build=s[5]?s[5].split("."):[],this.format()}format(){return this.version=`${this.major}.${this.minor}.${this.patch}`,this.prerelease.length&&(this.version+=`-${this.prerelease.join(".")}`),this.version}toString(){return this.version}compare(e){if(U("SemVer.compare",this.version,this.options,e),!(e instanceof t)){if(typeof e=="string"&&e===this.version)return 0;e=new t(e,this.options)}return e.version===this.version?0:this.compareMain(e)||this.comparePre(e)}compareMain(e){return e instanceof t||(e=new t(e,this.options)),this.major<e.major?-1:this.major>e.major?1:this.minor<e.minor?-1:this.minor>e.minor?1:this.patch<e.patch?-1:this.patch>e.patch?1:0}comparePre(e){if(e instanceof t||(e=new t(e,this.options)),this.prerelease.length&&!e.prerelease.length)return-1;if(!this.prerelease.length&&e.prerelease.length)return 1;if(!this.prerelease.length&&!e.prerelease.length)return 0;let r=0;do{let s=this.prerelease[r],n=e.prerelease[r];if(U("prerelease compare",r,s,n),s===void 0&&n===void 0)return 0;if(n===void 0)return 1;if(s===void 0)return-1;if(s===n)continue;return se(s,n)}while(++r)}compareBuild(e){e instanceof t||(e=new t(e,this.options));let r=0;do{let s=this.build[r],n=e.build[r];if(U("build compare",r,s,n),s===void 0&&n===void 0)return 0;if(n===void 0)return 1;if(s===void 0)return-1;if(s===n)continue;return se(s,n)}while(++r)}inc(e,r,s){if(e.startsWith("pre")){if(!r&&s===!1)throw new Error("invalid increment argument: identifier is empty");if(r){let n=`-${r}`.match(this.options.loose?X[k.PRERELEASELOOSE]:X[k.PRERELEASE]);if(!n||n[1]!==r)throw new Error(`invalid identifier: ${r}`)}}switch(e){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",r,s);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",r,s);break;case"prepatch":this.prerelease.length=0,this.inc("patch",r,s),this.inc("pre",r,s);break;case"prerelease":this.prerelease.length===0&&this.inc("patch",r,s),this.inc("pre",r,s);break;case"release":if(this.prerelease.length===0)throw new Error(`version ${this.raw} is not a prerelease`);this.prerelease.length=0;break;case"major":(this.minor!==0||this.patch!==0||this.prerelease.length===0)&&this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":(this.patch!==0||this.prerelease.length===0)&&this.minor++,this.patch=0,this.prerelease=[];break;case"patch":this.prerelease.length===0&&this.patch++,this.prerelease=[];break;case"pre":{let n=Number(s)?1:0;if(this.prerelease.length===0)this.prerelease=[n];else{let i=this.prerelease.length;for(;--i>=0;)typeof this.prerelease[i]=="number"&&(this.prerelease[i]++,i=-2);if(i===-1){if(r===this.prerelease.join(".")&&s===!1)throw new Error("invalid increment argument: identifier already exists");this.prerelease.push(n)}}if(r){let i=[r,n];s===!1&&(i=[r]),se(this.prerelease[0],r)===0?isNaN(this.prerelease[1])&&(this.prerelease=i):this.prerelease=i}break}default:throw new Error(`invalid increment argument: ${e}`)}return this.raw=this.format(),this.build.length&&(this.raw+=`+${this.build.join(".")}`),this}};ve.exports=ne});var w=p((vi,xe)=>{"use strict";var Pe=I(),_t=(t,e,r=!1)=>{if(t instanceof Pe)return t;try{return new Pe(t,e)}catch(s){if(!r)return null;throw s}};xe.exports=_t});var De=p((Pi,Ce)=>{"use strict";var Ht=w(),Wt=(t,e)=>{let r=Ht(t,e);return r?r.version:null};Ce.exports=Wt});var je=p((xi,ye)=>{"use strict";var Mt=w(),Yt=(t,e)=>{let r=Mt(t.trim().replace(/^[=v]+/,""),e);return r?r.version:null};ye.exports=Yt});var be=p((Ci,Ge)=>{"use strict";var Fe=I(),Bt=(t,e,r,s,n)=>{typeof r=="string"&&(n=s,s=r,r=void 0);try{return new Fe(t instanceof Fe?t.version:t,r).inc(e,s,n).version}catch(i){return null}};Ge.exports=Bt});var Xe=p((Di,Ve)=>{"use strict";var Ue=w(),zt=(t,e)=>{let r=Ue(t,null,!0),s=Ue(e,null,!0),n=r.compare(s);if(n===0)return null;let i=n>0,o=i?r:s,a=i?s:r,u=!!o.prerelease.length;if(!!a.prerelease.length&&!u){if(!a.patch&&!a.minor)return"major";if(a.compareMain(o)===0)return a.minor&&!a.patch?"minor":"patch"}let $=u?"pre":"";return r.major!==s.major?$+"major":r.minor!==s.minor?$+"minor":r.patch!==s.patch?$+"patch":"prerelease"};Ve.exports=zt});var _e=p((yi,ke)=>{"use strict";var Kt=I(),Zt=(t,e)=>new Kt(t,e).major;ke.exports=Zt});var We=p((ji,He)=>{"use strict";var Jt=I(),Qt=(t,e)=>new Jt(t,e).minor;He.exports=Qt});var Ye=p((Fi,Me)=>{"use strict";var es=I(),rs=(t,e)=>new es(t,e).patch;Me.exports=rs});var ze=p((Gi,Be)=>{"use strict";var ts=w(),ss=(t,e)=>{let r=ts(t,e);return r&&r.prerelease.length?r.prerelease:null};Be.exports=ss});var S=p((bi,Ze)=>{"use strict";var Ke=I(),ns=(t,e,r)=>new Ke(t,r).compare(new Ke(e,r));Ze.exports=ns});var Qe=p((Ui,Je)=>{"use strict";var is=S(),os=(t,e,r)=>is(e,t,r);Je.exports=os});var rr=p((Vi,er)=>{"use strict";var as=S(),cs=(t,e)=>as(t,e,!0);er.exports=cs});var _=p((Xi,sr)=>{"use strict";var tr=I(),ls=(t,e,r)=>{let s=new tr(t,r),n=new tr(e,r);return s.compare(n)||s.compareBuild(n)};sr.exports=ls});var ir=p((ki,nr)=>{"use strict";var us=_(),fs=(t,e)=>t.sort((r,s)=>us(r,s,e));nr.exports=fs});var ar=p((_i,or)=>{"use strict";var hs=_(),Es=(t,e)=>t.sort((r,s)=>hs(s,r,e));or.exports=Es});var C=p((Hi,cr)=>{"use strict";var ps=S(),ms=(t,e,r)=>ps(t,e,r)>0;cr.exports=ms});var H=p((Wi,lr)=>{"use strict";var $s=S(),Rs=(t,e,r)=>$s(t,e,r)<0;lr.exports=Rs});var ie=p((Mi,ur)=>{"use strict";var ds=S(),Is=(t,e,r)=>ds(t,e,r)===0;ur.exports=Is});var oe=p((Yi,fr)=>{"use strict";var gs=S(),Ls=(t,e,r)=>gs(t,e,r)!==0;fr.exports=Ls});var W=p((Bi,hr)=>{"use strict";var Ns=S(),Ss=(t,e,r)=>Ns(t,e,r)>=0;hr.exports=Ss});var M=p((zi,Er)=>{"use strict";var Os=S(),Ts=(t,e,r)=>Os(t,e,r)<=0;Er.exports=Ts});var ae=p((Ki,pr)=>{"use strict";var As=ie(),ws=oe(),qs=C(),vs=W(),Ps=H(),xs=M(),Cs=(t,e,r,s)=>{switch(e){case"===":return typeof t=="object"&&(t=t.version),typeof r=="object"&&(r=r.version),t===r;case"!==":return typeof t=="object"&&(t=t.version),typeof r=="object"&&(r=r.version),t!==r;case"":case"=":case"==":return As(t,r,s);case"!=":return ws(t,r,s);case">":return qs(t,r,s);case">=":return vs(t,r,s);case"<":return Ps(t,r,s);case"<=":return xs(t,r,s);default:throw new TypeError(`Invalid operator: ${e}`)}};pr.exports=Cs});var $r=p((Zi,mr)=>{"use strict";var Ds=I(),ys=w(),{safeRe:Y,t:B}=q(),js=(t,e)=>{if(t instanceof Ds)return t;if(typeof t=="number"&&(t=String(t)),typeof t!="string")return null;e=e||{};let r=null;if(!e.rtl)r=t.match(e.includePrerelease?Y[B.COERCEFULL]:Y[B.COERCE]);else{let u=e.includePrerelease?Y[B.COERCERTLFULL]:Y[B.COERCERTL],f;for(;(f=u.exec(t))&&(!r||r.index+r[0].length!==t.length);)(!r||f.index+f[0].length!==r.index+r[0].length)&&(r=f),u.lastIndex=f.index+f[1].length+f[2].length;u.lastIndex=-1}if(r===null)return null;let s=r[2],n=r[3]||"0",i=r[4]||"0",o=e.includePrerelease&&r[5]?`-${r[5]}`:"",a=e.includePrerelease&&r[6]?`+${r[6]}`:"";return ys(`${s}.${n}.${i}${o}${a}`,e)};mr.exports=js});var dr=p((Ji,Rr)=>{"use strict";var ce=class{constructor(){this.max=1e3,this.map=new Map}get(e){let r=this.map.get(e);if(r!==void 0)return this.map.delete(e),this.map.set(e,r),r}delete(e){return this.map.delete(e)}set(e,r){if(!this.delete(e)&&r!==void 0){if(this.map.size>=this.max){let n=this.map.keys().next().value;this.delete(n)}this.map.set(e,r)}return this}};Rr.exports=ce});var O=p((Qi,Nr)=>{"use strict";var Fs=/\s+/g,le=class t{constructor(e,r){if(r=bs(r),e instanceof t)return e.loose===!!r.loose&&e.includePrerelease===!!r.includePrerelease?e:new t(e.raw,r);if(e instanceof ue)return this.raw=e.value,this.set=[[e]],this.formatted=void 0,this;if(this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease,this.raw=e.trim().replace(Fs," "),this.set=this.raw.split("||").map(s=>this.parseRange(s.trim())).filter(s=>s.length),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${this.raw}`);if(this.set.length>1){let s=this.set[0];if(this.set=this.set.filter(n=>!gr(n[0])),this.set.length===0)this.set=[s];else if(this.set.length>1){for(let n of this.set)if(n.length===1&&Ws(n[0])){this.set=[n];break}}}this.formatted=void 0}get range(){if(this.formatted===void 0){this.formatted="";for(let e=0;e<this.set.length;e++){e>0&&(this.formatted+="||");let r=this.set[e];for(let s=0;s<r.length;s++)s>0&&(this.formatted+=" "),this.formatted+=r[s].toString().trim()}}return this.formatted}format(){return this.range}toString(){return this.range}parseRange(e){let s=((this.options.includePrerelease&&_s)|(this.options.loose&&Hs))+":"+e,n=Ir.get(s);if(n)return n;let i=this.options.loose,o=i?L[g.HYPHENRANGELOOSE]:L[g.HYPHENRANGE];e=e.replace(o,rn(this.options.includePrerelease)),R("hyphen replace",e),e=e.replace(L[g.COMPARATORTRIM],Vs),R("comparator trim",e),e=e.replace(L[g.TILDETRIM],Xs),R("tilde trim",e),e=e.replace(L[g.CARETTRIM],ks),R("caret trim",e);let a=e.split(" ").map(h=>Ms(h,this.options)).join(" ").split(/\s+/).map(h=>en(h,this.options));i&&(a=a.filter(h=>(R("loose invalid filter",h,this.options),!!h.match(L[g.COMPARATORLOOSE])))),R("range list",a);let u=new Map,f=a.map(h=>new ue(h,this.options));for(let h of f){if(gr(h))return[h];u.set(h.value,h)}u.size>1&&u.has("")&&u.delete("");let $=[...u.values()];return Ir.set(s,$),$}intersects(e,r){if(!(e instanceof t))throw new TypeError("a Range is required");return this.set.some(s=>Lr(s,r)&&e.set.some(n=>Lr(n,r)&&s.every(i=>n.every(o=>i.intersects(o,r)))))}test(e){if(!e)return!1;if(typeof e=="string")try{e=new Us(e,this.options)}catch(r){return!1}for(let r=0;r<this.set.length;r++)if(tn(this.set[r],e,this.options))return!0;return!1}};Nr.exports=le;var Gs=dr(),Ir=new Gs,bs=b(),ue=D(),R=x(),Us=I(),{safeRe:L,t:g,comparatorTrimReplace:Vs,tildeTrimReplace:Xs,caretTrimReplace:ks}=q(),{FLAG_INCLUDE_PRERELEASE:_s,FLAG_LOOSE:Hs}=P(),gr=t=>t.value==="<0.0.0-0",Ws=t=>t.value==="",Lr=(t,e)=>{let r=!0,s=t.slice(),n=s.pop();for(;r&&s.length;)r=s.every(i=>n.intersects(i,e)),n=s.pop();return r},Ms=(t,e)=>(t=t.replace(L[g.BUILD],""),R("comp",t,e),t=zs(t,e),R("caret",t),t=Ys(t,e),R("tildes",t),t=Zs(t,e),R("xrange",t),t=Qs(t,e),R("stars",t),t),N=t=>!t||t.toLowerCase()==="x"||t==="*",Ys=(t,e)=>t.trim().split(/\s+/).map(r=>Bs(r,e)).join(" "),Bs=(t,e)=>{let r=e.loose?L[g.TILDELOOSE]:L[g.TILDE];return t.replace(r,(s,n,i,o,a)=>{R("tilde",t,s,n,i,o,a);let u;return N(n)?u="":N(i)?u=`>=${n}.0.0 <${+n+1}.0.0-0`:N(o)?u=`>=${n}.${i}.0 <${n}.${+i+1}.0-0`:a?(R("replaceTilde pr",a),u=`>=${n}.${i}.${o}-${a} <${n}.${+i+1}.0-0`):u=`>=${n}.${i}.${o} <${n}.${+i+1}.0-0`,R("tilde return",u),u})},zs=(t,e)=>t.trim().split(/\s+/).map(r=>Ks(r,e)).join(" "),Ks=(t,e)=>{R("caret",t,e);let r=e.loose?L[g.CARETLOOSE]:L[g.CARET],s=e.includePrerelease?"-0":"";return t.replace(r,(n,i,o,a,u)=>{R("caret",t,n,i,o,a,u);let f;return N(i)?f="":N(o)?f=`>=${i}.0.0${s} <${+i+1}.0.0-0`:N(a)?i==="0"?f=`>=${i}.${o}.0${s} <${i}.${+o+1}.0-0`:f=`>=${i}.${o}.0${s} <${+i+1}.0.0-0`:u?(R("replaceCaret pr",u),i==="0"?o==="0"?f=`>=${i}.${o}.${a}-${u} <${i}.${o}.${+a+1}-0`:f=`>=${i}.${o}.${a}-${u} <${i}.${+o+1}.0-0`:f=`>=${i}.${o}.${a}-${u} <${+i+1}.0.0-0`):(R("no pr"),i==="0"?o==="0"?f=`>=${i}.${o}.${a}${s} <${i}.${o}.${+a+1}-0`:f=`>=${i}.${o}.${a}${s} <${i}.${+o+1}.0-0`:f=`>=${i}.${o}.${a} <${+i+1}.0.0-0`),R("caret return",f),f})},Zs=(t,e)=>(R("replaceXRanges",t,e),t.split(/\s+/).map(r=>Js(r,e)).join(" ")),Js=(t,e)=>{t=t.trim();let r=e.loose?L[g.XRANGELOOSE]:L[g.XRANGE];return t.replace(r,(s,n,i,o,a,u)=>{R("xRange",t,s,n,i,o,a,u);let f=N(i),$=f||N(o),h=$||N(a),d=h;return n==="="&&d&&(n=""),u=e.includePrerelease?"-0":"",f?n===">"||n==="<"?s="<0.0.0-0":s="*":n&&d?($&&(o=0),a=0,n===">"?(n=">=",$?(i=+i+1,o=0,a=0):(o=+o+1,a=0)):n==="<="&&(n="<",$?i=+i+1:o=+o+1),n==="<"&&(u="-0"),s=`${n+i}.${o}.${a}${u}`):$?s=`>=${i}.0.0${u} <${+i+1}.0.0-0`:h&&(s=`>=${i}.${o}.0${u} <${i}.${+o+1}.0-0`),R("xRange return",s),s})},Qs=(t,e)=>(R("replaceStars",t,e),t.trim().replace(L[g.STAR],"")),en=(t,e)=>(R("replaceGTE0",t,e),t.trim().replace(L[e.includePrerelease?g.GTE0PRE:g.GTE0],"")),rn=t=>(e,r,s,n,i,o,a,u,f,$,h,d)=>(N(s)?r="":N(n)?r=`>=${s}.0.0${t?"-0":""}`:N(i)?r=`>=${s}.${n}.0${t?"-0":""}`:o?r=`>=${r}`:r=`>=${r}${t?"-0":""}`,N(f)?u="":N($)?u=`<${+f+1}.0.0-0`:N(h)?u=`<${f}.${+$+1}.0-0`:d?u=`<=${f}.${$}.${h}-${d}`:t?u=`<${f}.${$}.${+h+1}-0`:u=`<=${u}`,`${r} ${u}`.trim()),tn=(t,e,r)=>{for(let s=0;s<t.length;s++)if(!t[s].test(e))return!1;if(e.prerelease.length&&!r.includePrerelease){for(let s=0;s<t.length;s++)if(R(t[s].semver),t[s].semver!==ue.ANY&&t[s].semver.prerelease.length>0){let n=t[s].semver;if(n.major===e.major&&n.minor===e.minor&&n.patch===e.patch)return!0}return!1}return!0}});var D=p((eo,qr)=>{"use strict";var y=Symbol("SemVer ANY"),Ee=class t{static get ANY(){return y}constructor(e,r){if(r=Sr(r),e instanceof t){if(e.loose===!!r.loose)return e;e=e.value}e=e.trim().split(/\s+/).join(" "),he("comparator",e,r),this.options=r,this.loose=!!r.loose,this.parse(e),this.semver===y?this.value="":this.value=this.operator+this.semver.version,he("comp",this)}parse(e){let r=this.options.loose?Or[Tr.COMPARATORLOOSE]:Or[Tr.COMPARATOR],s=e.match(r);if(!s)throw new TypeError(`Invalid comparator: ${e}`);this.operator=s[1]!==void 0?s[1]:"",this.operator==="="&&(this.operator=""),s[2]?this.semver=new Ar(s[2],this.options.loose):this.semver=y}toString(){return this.value}test(e){if(he("Comparator.test",e,this.options.loose),this.semver===y||e===y)return!0;if(typeof e=="string")try{e=new Ar(e,this.options)}catch(r){return!1}return fe(e,this.operator,this.semver,this.options)}intersects(e,r){if(!(e instanceof t))throw new TypeError("a Comparator is required");return this.operator===""?this.value===""?!0:new wr(e.value,r).test(this.value):e.operator===""?e.value===""?!0:new wr(this.value,r).test(e.semver):(r=Sr(r),r.includePrerelease&&(this.value==="<0.0.0-0"||e.value==="<0.0.0-0")||!r.includePrerelease&&(this.value.startsWith("<0.0.0")||e.value.startsWith("<0.0.0"))?!1:!!(this.operator.startsWith(">")&&e.operator.startsWith(">")||this.operator.startsWith("<")&&e.operator.startsWith("<")||this.semver.version===e.semver.version&&this.operator.includes("=")&&e.operator.includes("=")||fe(this.semver,"<",e.semver,r)&&this.operator.startsWith(">")&&e.operator.startsWith("<")||fe(this.semver,">",e.semver,r)&&this.operator.startsWith("<")&&e.operator.startsWith(">")))}};qr.exports=Ee;var Sr=b(),{safeRe:Or,t:Tr}=q(),fe=ae(),he=x(),Ar=I(),wr=O()});var j=p((ro,vr)=>{"use strict";var sn=O(),nn=(t,e,r)=>{try{e=new sn(e,r)}catch(s){return!1}return e.test(t)};vr.exports=nn});var xr=p((to,Pr)=>{"use strict";var on=O(),an=(t,e)=>new on(t,e).set.map(r=>r.map(s=>s.value).join(" ").trim().split(" "));Pr.exports=an});var Dr=p((so,Cr)=>{"use strict";var cn=I(),ln=O(),un=(t,e,r)=>{let s=null,n=null,i=null;try{i=new ln(e,r)}catch(o){return null}return t.forEach(o=>{i.test(o)&&(!s||n.compare(o)===-1)&&(s=o,n=new cn(s,r))}),s};Cr.exports=un});var jr=p((no,yr)=>{"use strict";var fn=I(),hn=O(),En=(t,e,r)=>{let s=null,n=null,i=null;try{i=new hn(e,r)}catch(o){return null}return t.forEach(o=>{i.test(o)&&(!s||n.compare(o)===1)&&(s=o,n=new fn(s,r))}),s};yr.exports=En});var br=p((io,Gr)=>{"use strict";var pe=I(),pn=O(),Fr=C(),mn=(t,e)=>{t=new pn(t,e);let r=new pe("0.0.0");if(t.test(r)||(r=new pe("0.0.0-0"),t.test(r)))return r;r=null;for(let s=0;s<t.set.length;++s){let n=t.set[s],i=null;n.forEach(o=>{let a=new pe(o.semver.version);switch(o.operator){case">":a.prerelease.length===0?a.patch++:a.prerelease.push(0),a.raw=a.format();case"":case">=":(!i||Fr(a,i))&&(i=a);break;case"<":case"<=":break;default:throw new Error(`Unexpected operation: ${o.operator}`)}}),i&&(!r||Fr(r,i))&&(r=i)}return r&&t.test(r)?r:null};Gr.exports=mn});var Vr=p((oo,Ur)=>{"use strict";var $n=O(),Rn=(t,e)=>{try{return new $n(t,e).range||"*"}catch(r){return null}};Ur.exports=Rn});var z=p((ao,Hr)=>{"use strict";var dn=I(),_r=D(),{ANY:In}=_r,gn=O(),Ln=j(),Xr=C(),kr=H(),Nn=M(),Sn=W(),On=(t,e,r,s)=>{t=new dn(t,s),e=new gn(e,s);let n,i,o,a,u;switch(r){case">":n=Xr,i=Nn,o=kr,a=">",u=">=";break;case"<":n=kr,i=Sn,o=Xr,a="<",u="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(Ln(t,e,s))return!1;for(let f=0;f<e.set.length;++f){let $=e.set[f],h=null,d=null;if($.forEach(E=>{E.semver===In&&(E=new _r(">=0.0.0")),h=h||E,d=d||E,n(E.semver,h.semver,s)?h=E:o(E.semver,d.semver,s)&&(d=E)}),h.operator===a||h.operator===u||(!d.operator||d.operator===a)&&i(t,d.semver))return!1;if(d.operator===u&&o(t,d.semver))return!1}return!0};Hr.exports=On});var Mr=p((co,Wr)=>{"use strict";var Tn=z(),An=(t,e,r)=>Tn(t,e,">",r);Wr.exports=An});var Br=p((lo,Yr)=>{"use strict";var wn=z(),qn=(t,e,r)=>wn(t,e,"<",r);Yr.exports=qn});var Zr=p((uo,Kr)=>{"use strict";var zr=O(),vn=(t,e,r)=>(t=new zr(t,r),e=new zr(e,r),t.intersects(e,r));Kr.exports=vn});var Qr=p((fo,Jr)=>{"use strict";var Pn=j(),xn=S();Jr.exports=(t,e,r)=>{let s=[],n=null,i=null,o=t.sort(($,h)=>xn($,h,r));for(let $ of o)Pn($,e,r)?(i=$,n||(n=$)):(i&&s.push([n,i]),i=null,n=null);n&&s.push([n,null]);let a=[];for(let[$,h]of s)$===h?a.push($):!h&&$===o[0]?a.push("*"):h?$===o[0]?a.push(`<=${h}`):a.push(`${$} - ${h}`):a.push(`>=${$}`);let u=a.join(" || "),f=typeof e.raw=="string"?e.raw:String(e);return u.length<f.length?u:e}});var it=p((ho,nt)=>{"use strict";var et=O(),$e=D(),{ANY:me}=$e,F=j(),Re=S(),Cn=(t,e,r={})=>{if(t===e)return!0;t=new et(t,r),e=new et(e,r);let s=!1;e:for(let n of t.set){for(let i of e.set){let o=yn(n,i,r);if(s=s||o!==null,o)continue e}if(s)return!1}return!0},Dn=[new $e(">=0.0.0-0")],rt=[new $e(">=0.0.0")],yn=(t,e,r)=>{if(t===e)return!0;if(t.length===1&&t[0].semver===me){if(e.length===1&&e[0].semver===me)return!0;r.includePrerelease?t=Dn:t=rt}if(e.length===1&&e[0].semver===me){if(r.includePrerelease)return!0;e=rt}let s=new Set,n,i;for(let E of t)E.operator===">"||E.operator===">="?n=tt(n,E,r):E.operator==="<"||E.operator==="<="?i=st(i,E,r):s.add(E.semver);if(s.size>1)return null;let o;if(n&&i){if(o=Re(n.semver,i.semver,r),o>0)return null;if(o===0&&(n.operator!==">="||i.operator!=="<="))return null}for(let E of s){if(n&&!F(E,String(n),r)||i&&!F(E,String(i),r))return null;for(let pt of e)if(!F(E,String(pt),r))return!1;return!0}let a,u,f,$,h=i&&!r.includePrerelease&&i.semver.prerelease.length?i.semver:!1,d=n&&!r.includePrerelease&&n.semver.prerelease.length?n.semver:!1;h&&h.prerelease.length===1&&i.operator==="<"&&h.prerelease[0]===0&&(h=!1);for(let E of e){if($=$||E.operator===">"||E.operator===">=",f=f||E.operator==="<"||E.operator==="<=",n){if(d&&E.semver.prerelease&&E.semver.prerelease.length&&E.semver.major===d.major&&E.semver.minor===d.minor&&E.semver.patch===d.patch&&(d=!1),E.operator===">"||E.operator===">="){if(a=tt(n,E,r),a===E&&a!==n)return!1}else if(n.operator===">="&&!F(n.semver,String(E),r))return!1}if(i){if(h&&E.semver.prerelease&&E.semver.prerelease.length&&E.semver.major===h.major&&E.semver.minor===h.minor&&E.semver.patch===h.patch&&(h=!1),E.operator==="<"||E.operator==="<="){if(u=st(i,E,r),u===E&&u!==i)return!1}else if(i.operator==="<="&&!F(i.semver,String(E),r))return!1}if(!E.operator&&(i||n)&&o!==0)return!1}return!(n&&f&&!i&&o!==0||i&&$&&!n&&o!==0||d||h)},tt=(t,e,r)=>{if(!t)return e;let s=Re(t.semver,e.semver,r);return s>0?t:s<0||e.operator===">"&&t.operator===">="?e:t},st=(t,e,r)=>{if(!t)return e;let s=Re(t.semver,e.semver,r);return s<0?t:s>0||e.operator==="<"&&t.operator==="<="?e:t};nt.exports=Cn});var lt=p((Eo,ct)=>{"use strict";var de=q(),ot=P(),jn=I(),at=te(),Fn=w(),Gn=De(),bn=je(),Un=be(),Vn=Xe(),Xn=_e(),kn=We(),_n=Ye(),Hn=ze(),Wn=S(),Mn=Qe(),Yn=rr(),Bn=_(),zn=ir(),Kn=ar(),Zn=C(),Jn=H(),Qn=ie(),ei=oe(),ri=W(),ti=M(),si=ae(),ni=$r(),ii=D(),oi=O(),ai=j(),ci=xr(),li=Dr(),ui=jr(),fi=br(),hi=Vr(),Ei=z(),pi=Mr(),mi=Br(),$i=Zr(),Ri=Qr(),di=it();ct.exports={parse:Fn,valid:Gn,clean:bn,inc:Un,diff:Vn,major:Xn,minor:kn,patch:_n,prerelease:Hn,compare:Wn,rcompare:Mn,compareLoose:Yn,compareBuild:Bn,sort:zn,rsort:Kn,gt:Zn,lt:Jn,eq:Qn,neq:ei,gte:ri,lte:ti,cmp:si,coerce:ni,Comparator:ii,Range:oi,satisfies:ai,toComparators:ci,maxSatisfying:li,minSatisfying:ui,minVersion:fi,validRange:hi,outside:Ei,gtr:pi,ltr:mi,intersects:$i,simplifyRange:Ri,subset:di,SemVer:jn,re:de.re,src:de.src,tokens:de.t,SEMVER_SPEC_VERSION:ot.SEMVER_SPEC_VERSION,RELEASE_TYPES:ot.RELEASE_TYPES,compareIdentifiers:at.compareIdentifiers,rcompareIdentifiers:at.rcompareIdentifiers}});var Ni={};gt(Ni,{ngAdd:()=>Li});module.exports=Nt(Ni);var Q=require("@angular-devkit/schematics/tasks");var J=require("@angular-devkit/schematics"),A=Lt(lt());var K=t=>JSON.stringify(t,null,2),Z=(t,e,r)=>{t.exists(e)?t.overwrite(e,r):t.create(e,r)};function Ie(t,e){try{return JSON.parse(e.read(t).toString())}catch(r){throw new J.SchematicsException(`Error when parsing ${t}: ${r.message}`)}}var ut=(t,e,r)=>{var n,i;let s=t.exists("package.json")&&Ie("package.json",t);if(s===void 0)throw new J.SchematicsException("Could not locate package.json");(n=s.devDependencies)!=null||(s.devDependencies={}),(i=s.dependencies)!=null||(s.dependencies={}),Object.keys(e).forEach(o=>{let a=e[o],u=a.dev?s.devDependencies:s.dependencies,f=u[o];if(f)try{(0,A.intersects)(f,a.version)||r.logger.warn(`\u26A0\uFE0F The ${o} devDependency specified in your package.json (${f}) does not fulfill AngularFire's dependency (${a.version})`)}catch($){f!==a.version&&r.logger.warn(`\u26A0\uFE0F The ${o} devDependency specified in your package.json (${f}) does not fulfill AngularFire's dependency (${a.version})`)}else u[o]=a.version}),Z(t,"package.json",K(s))},v="^12.18.0",ft=(t,e)=>{var i;if(!t.exists("package.json"))throw new J.SchematicsException("Could not locate package.json");let r=Ie("package.json",t),s=["dependencies","devDependencies"].filter(o=>{var a;return typeof((a=r[o])==null?void 0:a.firebase)=="string"});if(s.length===0)return(i=r.dependencies)!=null||(r.dependencies={}),r.dependencies.firebase=v,e.logger.info(`Added firebase ${v} to your package.json.`),Z(t,"package.json",K(r)),!0;let n=!1;for(let o of s){let a=r[o].firebase,u;try{u=(0,A.subset)(a,v)}catch(f){e.logger.warn(`\u26A0\uFE0F The firebase version in your package.json (${a}) is not a semver range, so it was left as-is; make sure it resolves inside ${v}, the range @angular/fire requires; a version outside it can leave the install with two copies of the firebase SDK.`);continue}u||(r[o].firebase=v,e.logger.info(`Updated the firebase version in your package.json from ${a} to ${v}, the range @angular/fire requires; a workspace range outside it can leave the install with a second copy of the firebase SDK, which fails at runtime.`),n=!0)}return n&&Z(t,"package.json",K(r)),n},Ii="21.0.0-rc.0-canary.36bab40",ht=(t,e,r=Ii)=>{if(!t.exists("package.json"))return;let s=Ie("package.json",t),n=["dependencies","devDependencies"].find(o=>{var a;return typeof((a=s[o])==null?void 0:a["@angular/fire"])=="string"});if(!n)return;let i=s[n]["@angular/fire"];if(i.startsWith("^")||i.startsWith("~")){if(!(0,A.valid)(r)){e.logger.warn("Could not determine the installed @angular/fire version; leaving the declared version range as-is.");return}(0,A.prerelease)(r)&&(0,A.satisfies)(r,i,{includePrerelease:!0})&&(s[n]["@angular/fire"]=r,Z(t,"package.json",K(s)),e.logger.info(`Pinned @angular/fire to the exact version ${r} \u2014 a prerelease range like ${i} also matches unreviewed canary builds, so a later install could silently change versions.`))}};var Et={};var Li=t=>(e,r)=>{ut(e,Et,r),ft(e,r),ht(e,r);let s=r.addTask(new Q.NodePackageInstallTask);return r.addTask(new Q.RunSchematicTask("ng-add-setup-project",t),[s]),e};0&&(module.exports={ngAdd});
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
},
|
|
9
9
|
"migration-v21": {
|
|
10
10
|
"version": "21.0.0",
|
|
11
|
-
"description": "Align the workspace's firebase dependency with the range @angular/fire 21 requires, and rewrite Vertex AI imports to Firebase AI Logic (getVertexAI callers keep the
|
|
11
|
+
"description": "Align the workspace's firebase dependency with the range @angular/fire 21 requires, and rewrite Vertex AI imports to Firebase AI Logic (getVertexAI callers keep the same backend, and a call that passed no location moves from us-central1 to global)",
|
|
12
12
|
"factory": "./update/v21#ngUpdate"
|
|
13
13
|
}
|
|
14
14
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
var jr=Object.create;var j=Object.defineProperty,kr=Object.defineProperties,Gr=Object.getOwnPropertyDescriptor,_r=Object.getOwnPropertyDescriptors,Ur=Object.getOwnPropertyNames,Te=Object.getOwnPropertySymbols,Br=Object.getPrototypeOf,Ce=Object.prototype.hasOwnProperty,Mr=Object.prototype.propertyIsEnumerable;var Oe=(t,e,r)=>e in t?j(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,oe=(t,e)=>{for(var r in e||(e={}))Ce.call(e,r)&&Oe(t,r,e[r]);if(Te)for(var r of Te(e))Mr.call(e,r)&&Oe(t,r,e[r]);return t},be=(t,e)=>kr(t,_r(e));var E=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),Xr=(t,e)=>{for(var r in e)j(t,r,{get:e[r],enumerable:!0})},Fe=(t,e,r,s)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of Ur(e))!Ce.call(t,i)&&i!==r&&j(t,i,{get:()=>e[i],enumerable:!(s=Gr(e,i))||s.enumerable});return t};var Hr=(t,e,r)=>(r=t!=null?jr(Br(t)):{},Fe(e||!t||!t.__esModule?j(r,"default",{value:t,enumerable:!0}):r,t)),Wr=t=>Fe(j({},"__esModule",{value:!0}),t);var k=E((go,De)=>{"use strict";var Yr="2.0.0",zr=Number.MAX_SAFE_INTEGER||9007199254740991,Kr=16,Qr=250,Zr=["major","premajor","minor","preminor","patch","prepatch","prerelease"];De.exports={MAX_LENGTH:256,MAX_SAFE_COMPONENT_LENGTH:Kr,MAX_SAFE_BUILD_LENGTH:Qr,MAX_SAFE_INTEGER:zr,RELEASE_TYPES:Zr,SEMVER_SPEC_VERSION:Yr,FLAG_INCLUDE_PRERELEASE:1,FLAG_LOOSE:2}});var G=E((Io,qe)=>{"use strict";var Jr=typeof process=="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?(...t)=>console.error("SEMVER",...t):()=>{};qe.exports=Jr});var F=E((w,Pe)=>{"use strict";var{MAX_SAFE_COMPONENT_LENGTH:ae,MAX_SAFE_BUILD_LENGTH:es,MAX_LENGTH:ts}=k(),rs=G();w=Pe.exports={};var ss=w.re=[],is=w.safeRe=[],p=w.src=[],ns=w.safeSrc=[],f=w.t={},os=0,ce="[a-zA-Z0-9-]",as=[["\\s",1],["\\d",ts],[ce,es]],cs=t=>{for(let[e,r]of as)t=t.split(`${e}*`).join(`${e}{0,${r}}`).split(`${e}+`).join(`${e}{1,${r}}`);return t},h=(t,e,r)=>{let s=cs(e),i=os++;rs(t,i,e),f[t]=i,p[i]=e,ns[i]=s,ss[i]=new RegExp(e,r?"g":void 0),is[i]=new RegExp(s,r?"g":void 0)};h("NUMERICIDENTIFIER","0|[1-9]\\d*");h("NUMERICIDENTIFIERLOOSE","\\d+");h("NONNUMERICIDENTIFIER",`\\d*[a-zA-Z-]${ce}*`);h("MAINVERSION",`(${p[f.NUMERICIDENTIFIER]})\\.(${p[f.NUMERICIDENTIFIER]})\\.(${p[f.NUMERICIDENTIFIER]})`);h("MAINVERSIONLOOSE",`(${p[f.NUMERICIDENTIFIERLOOSE]})\\.(${p[f.NUMERICIDENTIFIERLOOSE]})\\.(${p[f.NUMERICIDENTIFIERLOOSE]})`);h("PRERELEASEIDENTIFIER",`(?:${p[f.NONNUMERICIDENTIFIER]}|${p[f.NUMERICIDENTIFIER]})`);h("PRERELEASEIDENTIFIERLOOSE",`(?:${p[f.NONNUMERICIDENTIFIER]}|${p[f.NUMERICIDENTIFIERLOOSE]})`);h("PRERELEASE",`(?:-(${p[f.PRERELEASEIDENTIFIER]}(?:\\.${p[f.PRERELEASEIDENTIFIER]})*))`);h("PRERELEASELOOSE",`(?:-?(${p[f.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${p[f.PRERELEASEIDENTIFIERLOOSE]})*))`);h("BUILDIDENTIFIER",`${ce}+`);h("BUILD",`(?:\\+(${p[f.BUILDIDENTIFIER]}(?:\\.${p[f.BUILDIDENTIFIER]})*))`);h("FULLPLAIN",`v?${p[f.MAINVERSION]}${p[f.PRERELEASE]}?${p[f.BUILD]}?`);h("FULL",`^${p[f.FULLPLAIN]}$`);h("LOOSEPLAIN",`[v=\\s]*${p[f.MAINVERSIONLOOSE]}${p[f.PRERELEASELOOSE]}?${p[f.BUILD]}?`);h("LOOSE",`^${p[f.LOOSEPLAIN]}$`);h("GTLT","((?:<|>)?=?)");h("XRANGEIDENTIFIERLOOSE",`${p[f.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`);h("XRANGEIDENTIFIER",`${p[f.NUMERICIDENTIFIER]}|x|X|\\*`);h("XRANGEPLAIN",`[v=\\s]*(${p[f.XRANGEIDENTIFIER]})(?:\\.(${p[f.XRANGEIDENTIFIER]})(?:\\.(${p[f.XRANGEIDENTIFIER]})(?:${p[f.PRERELEASE]})?${p[f.BUILD]}?)?)?`);h("XRANGEPLAINLOOSE",`[v=\\s]*(${p[f.XRANGEIDENTIFIERLOOSE]})(?:\\.(${p[f.XRANGEIDENTIFIERLOOSE]})(?:\\.(${p[f.XRANGEIDENTIFIERLOOSE]})(?:${p[f.PRERELEASELOOSE]})?${p[f.BUILD]}?)?)?`);h("XRANGE",`^${p[f.GTLT]}\\s*${p[f.XRANGEPLAIN]}$`);h("XRANGELOOSE",`^${p[f.GTLT]}\\s*${p[f.XRANGEPLAINLOOSE]}$`);h("COERCEPLAIN",`(^|[^\\d])(\\d{1,${ae}})(?:\\.(\\d{1,${ae}}))?(?:\\.(\\d{1,${ae}}))?`);h("COERCE",`${p[f.COERCEPLAIN]}(?:$|[^\\d])`);h("COERCEFULL",p[f.COERCEPLAIN]+`(?:${p[f.PRERELEASE]})?(?:${p[f.BUILD]})?(?:$|[^\\d])`);h("COERCERTL",p[f.COERCE],!0);h("COERCERTLFULL",p[f.COERCEFULL],!0);h("LONETILDE","(?:~>?)");h("TILDETRIM",`(\\s*)${p[f.LONETILDE]}\\s+`,!0);w.tildeTrimReplace="$1~";h("TILDE",`^${p[f.LONETILDE]}${p[f.XRANGEPLAIN]}$`);h("TILDELOOSE",`^${p[f.LONETILDE]}${p[f.XRANGEPLAINLOOSE]}$`);h("LONECARET","(?:\\^)");h("CARETTRIM",`(\\s*)${p[f.LONECARET]}\\s+`,!0);w.caretTrimReplace="$1^";h("CARET",`^${p[f.LONECARET]}${p[f.XRANGEPLAIN]}$`);h("CARETLOOSE",`^${p[f.LONECARET]}${p[f.XRANGEPLAINLOOSE]}$`);h("COMPARATORLOOSE",`^${p[f.GTLT]}\\s*(${p[f.LOOSEPLAIN]})$|^$`);h("COMPARATOR",`^${p[f.GTLT]}\\s*(${p[f.FULLPLAIN]})$|^$`);h("COMPARATORTRIM",`(\\s*)${p[f.GTLT]}\\s*(${p[f.LOOSEPLAIN]}|${p[f.XRANGEPLAIN]})`,!0);w.comparatorTrimReplace="$1$2$3";h("HYPHENRANGE",`^\\s*(${p[f.XRANGEPLAIN]})\\s+-\\s+(${p[f.XRANGEPLAIN]})\\s*$`);h("HYPHENRANGELOOSE",`^\\s*(${p[f.XRANGEPLAINLOOSE]})\\s+-\\s+(${p[f.XRANGEPLAINLOOSE]})\\s*$`);h("STAR","(<|>)?=?\\s*\\*");h("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$");h("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")});var W=E((xo,Ve)=>{"use strict";var ls=Object.freeze({loose:!0}),us=Object.freeze({}),ps=t=>t?typeof t!="object"?ls:t:us;Ve.exports=ps});var le=E((So,Ge)=>{"use strict";var je=/^[0-9]+$/,ke=(t,e)=>{if(typeof t=="number"&&typeof e=="number")return t===e?0:t<e?-1:1;let r=je.test(t),s=je.test(e);return r&&s&&(t=+t,e=+e),t===e?0:r&&!s?-1:s&&!r?1:t<e?-1:1},fs=(t,e)=>ke(e,t);Ge.exports={compareIdentifiers:ke,rcompareIdentifiers:fs}});var x=E(($o,Ue)=>{"use strict";var Y=G(),{MAX_LENGTH:_e,MAX_SAFE_INTEGER:z}=k(),{safeRe:K,t:Q}=F(),ms=W(),{compareIdentifiers:ue}=le(),pe=class t{constructor(e,r){if(r=ms(r),e instanceof t){if(e.loose===!!r.loose&&e.includePrerelease===!!r.includePrerelease)return e;e=e.version}else if(typeof e!="string")throw new TypeError(`Invalid version. Must be a string. Got type "${typeof e}".`);if(e.length>_e)throw new TypeError(`version is longer than ${_e} characters`);Y("SemVer",e,r),this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease;let s=e.trim().match(r.loose?K[Q.LOOSE]:K[Q.FULL]);if(!s)throw new TypeError(`Invalid Version: ${e}`);if(this.raw=e,this.major=+s[1],this.minor=+s[2],this.patch=+s[3],this.major>z||this.major<0)throw new TypeError("Invalid major version");if(this.minor>z||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>z||this.patch<0)throw new TypeError("Invalid patch version");s[4]?this.prerelease=s[4].split(".").map(i=>{if(/^[0-9]+$/.test(i)){let n=+i;if(n>=0&&n<z)return n}return i}):this.prerelease=[],this.build=s[5]?s[5].split("."):[],this.format()}format(){return this.version=`${this.major}.${this.minor}.${this.patch}`,this.prerelease.length&&(this.version+=`-${this.prerelease.join(".")}`),this.version}toString(){return this.version}compare(e){if(Y("SemVer.compare",this.version,this.options,e),!(e instanceof t)){if(typeof e=="string"&&e===this.version)return 0;e=new t(e,this.options)}return e.version===this.version?0:this.compareMain(e)||this.comparePre(e)}compareMain(e){return e instanceof t||(e=new t(e,this.options)),this.major<e.major?-1:this.major>e.major?1:this.minor<e.minor?-1:this.minor>e.minor?1:this.patch<e.patch?-1:this.patch>e.patch?1:0}comparePre(e){if(e instanceof t||(e=new t(e,this.options)),this.prerelease.length&&!e.prerelease.length)return-1;if(!this.prerelease.length&&e.prerelease.length)return 1;if(!this.prerelease.length&&!e.prerelease.length)return 0;let r=0;do{let s=this.prerelease[r],i=e.prerelease[r];if(Y("prerelease compare",r,s,i),s===void 0&&i===void 0)return 0;if(i===void 0)return 1;if(s===void 0)return-1;if(s===i)continue;return ue(s,i)}while(++r)}compareBuild(e){e instanceof t||(e=new t(e,this.options));let r=0;do{let s=this.build[r],i=e.build[r];if(Y("build compare",r,s,i),s===void 0&&i===void 0)return 0;if(i===void 0)return 1;if(s===void 0)return-1;if(s===i)continue;return ue(s,i)}while(++r)}inc(e,r,s){if(e.startsWith("pre")){if(!r&&s===!1)throw new Error("invalid increment argument: identifier is empty");if(r){let i=`-${r}`.match(this.options.loose?K[Q.PRERELEASELOOSE]:K[Q.PRERELEASE]);if(!i||i[1]!==r)throw new Error(`invalid identifier: ${r}`)}}switch(e){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",r,s);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",r,s);break;case"prepatch":this.prerelease.length=0,this.inc("patch",r,s),this.inc("pre",r,s);break;case"prerelease":this.prerelease.length===0&&this.inc("patch",r,s),this.inc("pre",r,s);break;case"release":if(this.prerelease.length===0)throw new Error(`version ${this.raw} is not a prerelease`);this.prerelease.length=0;break;case"major":(this.minor!==0||this.patch!==0||this.prerelease.length===0)&&this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":(this.patch!==0||this.prerelease.length===0)&&this.minor++,this.patch=0,this.prerelease=[];break;case"patch":this.prerelease.length===0&&this.patch++,this.prerelease=[];break;case"pre":{let i=Number(s)?1:0;if(this.prerelease.length===0)this.prerelease=[i];else{let n=this.prerelease.length;for(;--n>=0;)typeof this.prerelease[n]=="number"&&(this.prerelease[n]++,n=-2);if(n===-1){if(r===this.prerelease.join(".")&&s===!1)throw new Error("invalid increment argument: identifier already exists");this.prerelease.push(i)}}if(r){let n=[r,i];s===!1&&(n=[r]),ue(this.prerelease[0],r)===0?isNaN(this.prerelease[1])&&(this.prerelease=n):this.prerelease=n}break}default:throw new Error(`invalid increment argument: ${e}`)}return this.raw=this.format(),this.build.length&&(this.raw+=`+${this.build.join(".")}`),this}};Ue.exports=pe});var O=E((Ro,Me)=>{"use strict";var Be=x(),ds=(t,e,r=!1)=>{if(t instanceof Be)return t;try{return new Be(t,e)}catch(s){if(!r)return null;throw s}};Me.exports=ds});var He=E((Ao,Xe)=>{"use strict";var Es=O(),hs=(t,e)=>{let r=Es(t,e);return r?r.version:null};Xe.exports=hs});var Ye=E((No,We)=>{"use strict";var gs=O(),Is=(t,e)=>{let r=gs(t.trim().replace(/^[=v]+/,""),e);return r?r.version:null};We.exports=Is});var Qe=E((wo,Ke)=>{"use strict";var ze=x(),xs=(t,e,r,s,i)=>{typeof r=="string"&&(i=s,s=r,r=void 0);try{return new ze(t instanceof ze?t.version:t,r).inc(e,s,i).version}catch(n){return null}};Ke.exports=xs});var et=E((Lo,Je)=>{"use strict";var Ze=O(),Ss=(t,e)=>{let r=Ze(t,null,!0),s=Ze(e,null,!0),i=r.compare(s);if(i===0)return null;let n=i>0,o=n?r:s,a=n?s:r,c=!!o.prerelease.length;if(!!a.prerelease.length&&!c){if(!a.patch&&!a.minor)return"major";if(a.compareMain(o)===0)return a.minor&&!a.patch?"minor":"patch"}let m=c?"pre":"";return r.major!==s.major?m+"major":r.minor!==s.minor?m+"minor":r.patch!==s.patch?m+"patch":"prerelease"};Je.exports=Ss});var rt=E((yo,tt)=>{"use strict";var $s=x(),Rs=(t,e)=>new $s(t,e).major;tt.exports=Rs});var it=E((vo,st)=>{"use strict";var As=x(),Ns=(t,e)=>new As(t,e).minor;st.exports=Ns});var ot=E((To,nt)=>{"use strict";var ws=x(),Ls=(t,e)=>new ws(t,e).patch;nt.exports=Ls});var ct=E((Oo,at)=>{"use strict";var ys=O(),vs=(t,e)=>{let r=ys(t,e);return r&&r.prerelease.length?r.prerelease:null};at.exports=vs});var A=E((Co,ut)=>{"use strict";var lt=x(),Ts=(t,e,r)=>new lt(t,r).compare(new lt(e,r));ut.exports=Ts});var ft=E((bo,pt)=>{"use strict";var Os=A(),Cs=(t,e,r)=>Os(e,t,r);pt.exports=Cs});var dt=E((Fo,mt)=>{"use strict";var bs=A(),Fs=(t,e)=>bs(t,e,!0);mt.exports=Fs});var Z=E((Do,ht)=>{"use strict";var Et=x(),Ds=(t,e,r)=>{let s=new Et(t,r),i=new Et(e,r);return s.compare(i)||s.compareBuild(i)};ht.exports=Ds});var It=E((qo,gt)=>{"use strict";var qs=Z(),Ps=(t,e)=>t.sort((r,s)=>qs(r,s,e));gt.exports=Ps});var St=E((Po,xt)=>{"use strict";var Vs=Z(),js=(t,e)=>t.sort((r,s)=>Vs(s,r,e));xt.exports=js});var _=E((Vo,$t)=>{"use strict";var ks=A(),Gs=(t,e,r)=>ks(t,e,r)>0;$t.exports=Gs});var J=E((jo,Rt)=>{"use strict";var _s=A(),Us=(t,e,r)=>_s(t,e,r)<0;Rt.exports=Us});var fe=E((ko,At)=>{"use strict";var Bs=A(),Ms=(t,e,r)=>Bs(t,e,r)===0;At.exports=Ms});var me=E((Go,Nt)=>{"use strict";var Xs=A(),Hs=(t,e,r)=>Xs(t,e,r)!==0;Nt.exports=Hs});var ee=E((_o,wt)=>{"use strict";var Ws=A(),Ys=(t,e,r)=>Ws(t,e,r)>=0;wt.exports=Ys});var te=E((Uo,Lt)=>{"use strict";var zs=A(),Ks=(t,e,r)=>zs(t,e,r)<=0;Lt.exports=Ks});var de=E((Bo,yt)=>{"use strict";var Qs=fe(),Zs=me(),Js=_(),ei=ee(),ti=J(),ri=te(),si=(t,e,r,s)=>{switch(e){case"===":return typeof t=="object"&&(t=t.version),typeof r=="object"&&(r=r.version),t===r;case"!==":return typeof t=="object"&&(t=t.version),typeof r=="object"&&(r=r.version),t!==r;case"":case"=":case"==":return Qs(t,r,s);case"!=":return Zs(t,r,s);case">":return Js(t,r,s);case">=":return ei(t,r,s);case"<":return ti(t,r,s);case"<=":return ri(t,r,s);default:throw new TypeError(`Invalid operator: ${e}`)}};yt.exports=si});var Tt=E((Mo,vt)=>{"use strict";var ii=x(),ni=O(),{safeRe:re,t:se}=F(),oi=(t,e)=>{if(t instanceof ii)return t;if(typeof t=="number"&&(t=String(t)),typeof t!="string")return null;e=e||{};let r=null;if(!e.rtl)r=t.match(e.includePrerelease?re[se.COERCEFULL]:re[se.COERCE]);else{let c=e.includePrerelease?re[se.COERCERTLFULL]:re[se.COERCERTL],l;for(;(l=c.exec(t))&&(!r||r.index+r[0].length!==t.length);)(!r||l.index+l[0].length!==r.index+r[0].length)&&(r=l),c.lastIndex=l.index+l[1].length+l[2].length;c.lastIndex=-1}if(r===null)return null;let s=r[2],i=r[3]||"0",n=r[4]||"0",o=e.includePrerelease&&r[5]?`-${r[5]}`:"",a=e.includePrerelease&&r[6]?`+${r[6]}`:"";return ni(`${s}.${i}.${n}${o}${a}`,e)};vt.exports=oi});var Ct=E((Xo,Ot)=>{"use strict";var Ee=class{constructor(){this.max=1e3,this.map=new Map}get(e){let r=this.map.get(e);if(r!==void 0)return this.map.delete(e),this.map.set(e,r),r}delete(e){return this.map.delete(e)}set(e,r){if(!this.delete(e)&&r!==void 0){if(this.map.size>=this.max){let i=this.map.keys().next().value;this.delete(i)}this.map.set(e,r)}return this}};Ot.exports=Ee});var N=E((Ho,qt)=>{"use strict";var ai=/\s+/g,he=class t{constructor(e,r){if(r=li(r),e instanceof t)return e.loose===!!r.loose&&e.includePrerelease===!!r.includePrerelease?e:new t(e.raw,r);if(e instanceof ge)return this.raw=e.value,this.set=[[e]],this.formatted=void 0,this;if(this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease,this.raw=e.trim().replace(ai," "),this.set=this.raw.split("||").map(s=>this.parseRange(s.trim())).filter(s=>s.length),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${this.raw}`);if(this.set.length>1){let s=this.set[0];if(this.set=this.set.filter(i=>!Ft(i[0])),this.set.length===0)this.set=[s];else if(this.set.length>1){for(let i of this.set)if(i.length===1&&hi(i[0])){this.set=[i];break}}}this.formatted=void 0}get range(){if(this.formatted===void 0){this.formatted="";for(let e=0;e<this.set.length;e++){e>0&&(this.formatted+="||");let r=this.set[e];for(let s=0;s<r.length;s++)s>0&&(this.formatted+=" "),this.formatted+=r[s].toString().trim()}}return this.formatted}format(){return this.range}toString(){return this.range}parseRange(e){let s=((this.options.includePrerelease&&di)|(this.options.loose&&Ei))+":"+e,i=bt.get(s);if(i)return i;let n=this.options.loose,o=n?$[S.HYPHENRANGELOOSE]:$[S.HYPHENRANGE];e=e.replace(o,Li(this.options.includePrerelease)),I("hyphen replace",e),e=e.replace($[S.COMPARATORTRIM],pi),I("comparator trim",e),e=e.replace($[S.TILDETRIM],fi),I("tilde trim",e),e=e.replace($[S.CARETTRIM],mi),I("caret trim",e);let a=e.split(" ").map(u=>gi(u,this.options)).join(" ").split(/\s+/).map(u=>wi(u,this.options));n&&(a=a.filter(u=>(I("loose invalid filter",u,this.options),!!u.match($[S.COMPARATORLOOSE])))),I("range list",a);let c=new Map,l=a.map(u=>new ge(u,this.options));for(let u of l){if(Ft(u))return[u];c.set(u.value,u)}c.size>1&&c.has("")&&c.delete("");let m=[...c.values()];return bt.set(s,m),m}intersects(e,r){if(!(e instanceof t))throw new TypeError("a Range is required");return this.set.some(s=>Dt(s,r)&&e.set.some(i=>Dt(i,r)&&s.every(n=>i.every(o=>n.intersects(o,r)))))}test(e){if(!e)return!1;if(typeof e=="string")try{e=new ui(e,this.options)}catch(r){return!1}for(let r=0;r<this.set.length;r++)if(yi(this.set[r],e,this.options))return!0;return!1}};qt.exports=he;var ci=Ct(),bt=new ci,li=W(),ge=U(),I=G(),ui=x(),{safeRe:$,t:S,comparatorTrimReplace:pi,tildeTrimReplace:fi,caretTrimReplace:mi}=F(),{FLAG_INCLUDE_PRERELEASE:di,FLAG_LOOSE:Ei}=k(),Ft=t=>t.value==="<0.0.0-0",hi=t=>t.value==="",Dt=(t,e)=>{let r=!0,s=t.slice(),i=s.pop();for(;r&&s.length;)r=s.every(n=>i.intersects(n,e)),i=s.pop();return r},gi=(t,e)=>(t=t.replace($[S.BUILD],""),I("comp",t,e),t=Si(t,e),I("caret",t),t=Ii(t,e),I("tildes",t),t=Ri(t,e),I("xrange",t),t=Ni(t,e),I("stars",t),t),R=t=>!t||t.toLowerCase()==="x"||t==="*",Ii=(t,e)=>t.trim().split(/\s+/).map(r=>xi(r,e)).join(" "),xi=(t,e)=>{let r=e.loose?$[S.TILDELOOSE]:$[S.TILDE];return t.replace(r,(s,i,n,o,a)=>{I("tilde",t,s,i,n,o,a);let c;return R(i)?c="":R(n)?c=`>=${i}.0.0 <${+i+1}.0.0-0`:R(o)?c=`>=${i}.${n}.0 <${i}.${+n+1}.0-0`:a?(I("replaceTilde pr",a),c=`>=${i}.${n}.${o}-${a} <${i}.${+n+1}.0-0`):c=`>=${i}.${n}.${o} <${i}.${+n+1}.0-0`,I("tilde return",c),c})},Si=(t,e)=>t.trim().split(/\s+/).map(r=>$i(r,e)).join(" "),$i=(t,e)=>{I("caret",t,e);let r=e.loose?$[S.CARETLOOSE]:$[S.CARET],s=e.includePrerelease?"-0":"";return t.replace(r,(i,n,o,a,c)=>{I("caret",t,i,n,o,a,c);let l;return R(n)?l="":R(o)?l=`>=${n}.0.0${s} <${+n+1}.0.0-0`:R(a)?n==="0"?l=`>=${n}.${o}.0${s} <${n}.${+o+1}.0-0`:l=`>=${n}.${o}.0${s} <${+n+1}.0.0-0`:c?(I("replaceCaret pr",c),n==="0"?o==="0"?l=`>=${n}.${o}.${a}-${c} <${n}.${o}.${+a+1}-0`:l=`>=${n}.${o}.${a}-${c} <${n}.${+o+1}.0-0`:l=`>=${n}.${o}.${a}-${c} <${+n+1}.0.0-0`):(I("no pr"),n==="0"?o==="0"?l=`>=${n}.${o}.${a}${s} <${n}.${o}.${+a+1}-0`:l=`>=${n}.${o}.${a}${s} <${n}.${+o+1}.0-0`:l=`>=${n}.${o}.${a} <${+n+1}.0.0-0`),I("caret return",l),l})},Ri=(t,e)=>(I("replaceXRanges",t,e),t.split(/\s+/).map(r=>Ai(r,e)).join(" ")),Ai=(t,e)=>{t=t.trim();let r=e.loose?$[S.XRANGELOOSE]:$[S.XRANGE];return t.replace(r,(s,i,n,o,a,c)=>{I("xRange",t,s,i,n,o,a,c);let l=R(n),m=l||R(o),u=m||R(a),g=u;return i==="="&&g&&(i=""),c=e.includePrerelease?"-0":"",l?i===">"||i==="<"?s="<0.0.0-0":s="*":i&&g?(m&&(o=0),a=0,i===">"?(i=">=",m?(n=+n+1,o=0,a=0):(o=+o+1,a=0)):i==="<="&&(i="<",m?n=+n+1:o=+o+1),i==="<"&&(c="-0"),s=`${i+n}.${o}.${a}${c}`):m?s=`>=${n}.0.0${c} <${+n+1}.0.0-0`:u&&(s=`>=${n}.${o}.0${c} <${n}.${+o+1}.0-0`),I("xRange return",s),s})},Ni=(t,e)=>(I("replaceStars",t,e),t.trim().replace($[S.STAR],"")),wi=(t,e)=>(I("replaceGTE0",t,e),t.trim().replace($[e.includePrerelease?S.GTE0PRE:S.GTE0],"")),Li=t=>(e,r,s,i,n,o,a,c,l,m,u,g)=>(R(s)?r="":R(i)?r=`>=${s}.0.0${t?"-0":""}`:R(n)?r=`>=${s}.${i}.0${t?"-0":""}`:o?r=`>=${r}`:r=`>=${r}${t?"-0":""}`,R(l)?c="":R(m)?c=`<${+l+1}.0.0-0`:R(u)?c=`<${l}.${+m+1}.0-0`:g?c=`<=${l}.${m}.${u}-${g}`:t?c=`<${l}.${m}.${+u+1}-0`:c=`<=${c}`,`${r} ${c}`.trim()),yi=(t,e,r)=>{for(let s=0;s<t.length;s++)if(!t[s].test(e))return!1;if(e.prerelease.length&&!r.includePrerelease){for(let s=0;s<t.length;s++)if(I(t[s].semver),t[s].semver!==ge.ANY&&t[s].semver.prerelease.length>0){let i=t[s].semver;if(i.major===e.major&&i.minor===e.minor&&i.patch===e.patch)return!0}return!1}return!0}});var U=E((Wo,_t)=>{"use strict";var B=Symbol("SemVer ANY"),Se=class t{static get ANY(){return B}constructor(e,r){if(r=Pt(r),e instanceof t){if(e.loose===!!r.loose)return e;e=e.value}e=e.trim().split(/\s+/).join(" "),xe("comparator",e,r),this.options=r,this.loose=!!r.loose,this.parse(e),this.semver===B?this.value="":this.value=this.operator+this.semver.version,xe("comp",this)}parse(e){let r=this.options.loose?Vt[jt.COMPARATORLOOSE]:Vt[jt.COMPARATOR],s=e.match(r);if(!s)throw new TypeError(`Invalid comparator: ${e}`);this.operator=s[1]!==void 0?s[1]:"",this.operator==="="&&(this.operator=""),s[2]?this.semver=new kt(s[2],this.options.loose):this.semver=B}toString(){return this.value}test(e){if(xe("Comparator.test",e,this.options.loose),this.semver===B||e===B)return!0;if(typeof e=="string")try{e=new kt(e,this.options)}catch(r){return!1}return Ie(e,this.operator,this.semver,this.options)}intersects(e,r){if(!(e instanceof t))throw new TypeError("a Comparator is required");return this.operator===""?this.value===""?!0:new Gt(e.value,r).test(this.value):e.operator===""?e.value===""?!0:new Gt(this.value,r).test(e.semver):(r=Pt(r),r.includePrerelease&&(this.value==="<0.0.0-0"||e.value==="<0.0.0-0")||!r.includePrerelease&&(this.value.startsWith("<0.0.0")||e.value.startsWith("<0.0.0"))?!1:!!(this.operator.startsWith(">")&&e.operator.startsWith(">")||this.operator.startsWith("<")&&e.operator.startsWith("<")||this.semver.version===e.semver.version&&this.operator.includes("=")&&e.operator.includes("=")||Ie(this.semver,"<",e.semver,r)&&this.operator.startsWith(">")&&e.operator.startsWith("<")||Ie(this.semver,">",e.semver,r)&&this.operator.startsWith("<")&&e.operator.startsWith(">")))}};_t.exports=Se;var Pt=W(),{safeRe:Vt,t:jt}=F(),Ie=de(),xe=G(),kt=x(),Gt=N()});var M=E((Yo,Ut)=>{"use strict";var vi=N(),Ti=(t,e,r)=>{try{e=new vi(e,r)}catch(s){return!1}return e.test(t)};Ut.exports=Ti});var Mt=E((zo,Bt)=>{"use strict";var Oi=N(),Ci=(t,e)=>new Oi(t,e).set.map(r=>r.map(s=>s.value).join(" ").trim().split(" "));Bt.exports=Ci});var Ht=E((Ko,Xt)=>{"use strict";var bi=x(),Fi=N(),Di=(t,e,r)=>{let s=null,i=null,n=null;try{n=new Fi(e,r)}catch(o){return null}return t.forEach(o=>{n.test(o)&&(!s||i.compare(o)===-1)&&(s=o,i=new bi(s,r))}),s};Xt.exports=Di});var Yt=E((Qo,Wt)=>{"use strict";var qi=x(),Pi=N(),Vi=(t,e,r)=>{let s=null,i=null,n=null;try{n=new Pi(e,r)}catch(o){return null}return t.forEach(o=>{n.test(o)&&(!s||i.compare(o)===1)&&(s=o,i=new qi(s,r))}),s};Wt.exports=Vi});var Qt=E((Zo,Kt)=>{"use strict";var $e=x(),ji=N(),zt=_(),ki=(t,e)=>{t=new ji(t,e);let r=new $e("0.0.0");if(t.test(r)||(r=new $e("0.0.0-0"),t.test(r)))return r;r=null;for(let s=0;s<t.set.length;++s){let i=t.set[s],n=null;i.forEach(o=>{let a=new $e(o.semver.version);switch(o.operator){case">":a.prerelease.length===0?a.patch++:a.prerelease.push(0),a.raw=a.format();case"":case">=":(!n||zt(a,n))&&(n=a);break;case"<":case"<=":break;default:throw new Error(`Unexpected operation: ${o.operator}`)}}),n&&(!r||zt(r,n))&&(r=n)}return r&&t.test(r)?r:null};Kt.exports=ki});var Jt=E((Jo,Zt)=>{"use strict";var Gi=N(),_i=(t,e)=>{try{return new Gi(t,e).range||"*"}catch(r){return null}};Zt.exports=_i});var ie=E((ea,sr)=>{"use strict";var Ui=x(),rr=U(),{ANY:Bi}=rr,Mi=N(),Xi=M(),er=_(),tr=J(),Hi=te(),Wi=ee(),Yi=(t,e,r,s)=>{t=new Ui(t,s),e=new Mi(e,s);let i,n,o,a,c;switch(r){case">":i=er,n=Hi,o=tr,a=">",c=">=";break;case"<":i=tr,n=Wi,o=er,a="<",c="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(Xi(t,e,s))return!1;for(let l=0;l<e.set.length;++l){let m=e.set[l],u=null,g=null;if(m.forEach(d=>{d.semver===Bi&&(d=new rr(">=0.0.0")),u=u||d,g=g||d,i(d.semver,u.semver,s)?u=d:o(d.semver,g.semver,s)&&(g=d)}),u.operator===a||u.operator===c||(!g.operator||g.operator===a)&&n(t,g.semver))return!1;if(g.operator===c&&o(t,g.semver))return!1}return!0};sr.exports=Yi});var nr=E((ta,ir)=>{"use strict";var zi=ie(),Ki=(t,e,r)=>zi(t,e,">",r);ir.exports=Ki});var ar=E((ra,or)=>{"use strict";var Qi=ie(),Zi=(t,e,r)=>Qi(t,e,"<",r);or.exports=Zi});var ur=E((sa,lr)=>{"use strict";var cr=N(),Ji=(t,e,r)=>(t=new cr(t,r),e=new cr(e,r),t.intersects(e,r));lr.exports=Ji});var fr=E((ia,pr)=>{"use strict";var en=M(),tn=A();pr.exports=(t,e,r)=>{let s=[],i=null,n=null,o=t.sort((m,u)=>tn(m,u,r));for(let m of o)en(m,e,r)?(n=m,i||(i=m)):(n&&s.push([i,n]),n=null,i=null);i&&s.push([i,null]);let a=[];for(let[m,u]of s)m===u?a.push(m):!u&&m===o[0]?a.push("*"):u?m===o[0]?a.push(`<=${u}`):a.push(`${m} - ${u}`):a.push(`>=${m}`);let c=a.join(" || "),l=typeof e.raw=="string"?e.raw:String(e);return c.length<l.length?c:e}});var Ir=E((na,gr)=>{"use strict";var mr=N(),Ae=U(),{ANY:Re}=Ae,X=M(),Ne=A(),rn=(t,e,r={})=>{if(t===e)return!0;t=new mr(t,r),e=new mr(e,r);let s=!1;e:for(let i of t.set){for(let n of e.set){let o=nn(i,n,r);if(s=s||o!==null,o)continue e}if(s)return!1}return!0},sn=[new Ae(">=0.0.0-0")],dr=[new Ae(">=0.0.0")],nn=(t,e,r)=>{if(t===e)return!0;if(t.length===1&&t[0].semver===Re){if(e.length===1&&e[0].semver===Re)return!0;r.includePrerelease?t=sn:t=dr}if(e.length===1&&e[0].semver===Re){if(r.includePrerelease)return!0;e=dr}let s=new Set,i,n;for(let d of t)d.operator===">"||d.operator===">="?i=Er(i,d,r):d.operator==="<"||d.operator==="<="?n=hr(n,d,r):s.add(d.semver);if(s.size>1)return null;let o;if(i&&n){if(o=Ne(i.semver,n.semver,r),o>0)return null;if(o===0&&(i.operator!==">="||n.operator!=="<="))return null}for(let d of s){if(i&&!X(d,String(i),r)||n&&!X(d,String(n),r))return null;for(let H of e)if(!X(d,String(H),r))return!1;return!0}let a,c,l,m,u=n&&!r.includePrerelease&&n.semver.prerelease.length?n.semver:!1,g=i&&!r.includePrerelease&&i.semver.prerelease.length?i.semver:!1;u&&u.prerelease.length===1&&n.operator==="<"&&u.prerelease[0]===0&&(u=!1);for(let d of e){if(m=m||d.operator===">"||d.operator===">=",l=l||d.operator==="<"||d.operator==="<=",i){if(g&&d.semver.prerelease&&d.semver.prerelease.length&&d.semver.major===g.major&&d.semver.minor===g.minor&&d.semver.patch===g.patch&&(g=!1),d.operator===">"||d.operator===">="){if(a=Er(i,d,r),a===d&&a!==i)return!1}else if(i.operator===">="&&!X(i.semver,String(d),r))return!1}if(n){if(u&&d.semver.prerelease&&d.semver.prerelease.length&&d.semver.major===u.major&&d.semver.minor===u.minor&&d.semver.patch===u.patch&&(u=!1),d.operator==="<"||d.operator==="<="){if(c=hr(n,d,r),c===d&&c!==n)return!1}else if(n.operator==="<="&&!X(n.semver,String(d),r))return!1}if(!d.operator&&(n||i)&&o!==0)return!1}return!(i&&l&&!n&&o!==0||n&&m&&!i&&o!==0||g||u)},Er=(t,e,r)=>{if(!t)return e;let s=Ne(t.semver,e.semver,r);return s>0?t:s<0||e.operator===">"&&t.operator===">="?e:t},hr=(t,e,r)=>{if(!t)return e;let s=Ne(t.semver,e.semver,r);return s<0?t:s>0||e.operator==="<"&&t.operator==="<="?e:t};gr.exports=rn});var Rr=E((oa,$r)=>{"use strict";var we=F(),xr=k(),on=x(),Sr=le(),an=O(),cn=He(),ln=Ye(),un=Qe(),pn=et(),fn=rt(),mn=it(),dn=ot(),En=ct(),hn=A(),gn=ft(),In=dt(),xn=Z(),Sn=It(),$n=St(),Rn=_(),An=J(),Nn=fe(),wn=me(),Ln=ee(),yn=te(),vn=de(),Tn=Tt(),On=U(),Cn=N(),bn=M(),Fn=Mt(),Dn=Ht(),qn=Yt(),Pn=Qt(),Vn=Jt(),jn=ie(),kn=nr(),Gn=ar(),_n=ur(),Un=fr(),Bn=Ir();$r.exports={parse:an,valid:cn,clean:ln,inc:un,diff:pn,major:fn,minor:mn,patch:dn,prerelease:En,compare:hn,rcompare:gn,compareLoose:In,compareBuild:xn,sort:Sn,rsort:$n,gt:Rn,lt:An,eq:Nn,neq:wn,gte:Ln,lte:yn,cmp:vn,coerce:Tn,Comparator:On,Range:Cn,satisfies:bn,toComparators:Fn,maxSatisfying:Dn,minSatisfying:qn,minVersion:Pn,validRange:Vn,outside:jn,gtr:kn,ltr:Gn,intersects:_n,simplifyRange:Un,subset:Bn,SemVer:on,re:we.re,src:we.src,tokens:we.t,SEMVER_SPEC_VERSION:xr.SEMVER_SPEC_VERSION,RELEASE_TYPES:xr.RELEASE_TYPES,compareIdentifiers:Sr.compareIdentifiers,rcompareIdentifiers:Sr.rcompareIdentifiers}});var Eo={};Xr(Eo,{ngUpdate:()=>mo});module.exports=Wr(Eo);var Vr=require("@angular-devkit/schematics/tasks/index.js");var Le=require("@angular-devkit/schematics"),q=Hr(Rr());var Ar=t=>JSON.stringify(t,null,2),ne=(t,e,r)=>{t.exists(e)?t.overwrite(e,r):t.create(e,r)};function ye(t,e){try{return JSON.parse(e.read(t).toString())}catch(r){throw new Le.SchematicsException(`Error when parsing ${t}: ${r.message}`)}}var D="^12.18.0",Nr=(t,e)=>{var n;if(!t.exists("package.json"))throw new Le.SchematicsException("Could not locate package.json");let r=ye("package.json",t),s=["dependencies","devDependencies"].filter(o=>{var a;return typeof((a=r[o])==null?void 0:a.firebase)=="string"});if(s.length===0)return(n=r.dependencies)!=null||(r.dependencies={}),r.dependencies.firebase=D,e.logger.info(`Added firebase ${D} to your package.json.`),ne(t,"package.json",Ar(r)),!0;let i=!1;for(let o of s){let a=r[o].firebase,c;try{c=(0,q.subset)(a,D)}catch(l){e.logger.warn(`\u26A0\uFE0F The firebase version in your package.json (${a}) is not a semver range, so it was left as-is; make sure it resolves inside ${D}, the range @angular/fire requires; a version outside it can leave the install with two copies of the firebase SDK.`);continue}c||(r[o].firebase=D,e.logger.info(`Updated the firebase version in your package.json from ${a} to ${D}, the range @angular/fire requires; a workspace range outside it can leave the install with a second copy of the firebase SDK, which fails at runtime.`),i=!0)}return i&&ne(t,"package.json",Ar(r)),i};var qr=require("path");var wr=require("path"),Lr=()=>{if(typeof require!="function")return;let t=[()=>require("typescript"),()=>require("module").createRequire((0,wr.join)(process.cwd(),"package.json"))("typescript")];for(let e of t)try{return e()}catch(r){}};var P=(t,e,r)=>{let s=[e];for(;s.length>0;){let i=s.pop();if(!i||r(i)===!1)continue;let n=[];t.forEachChild(i,o=>{n.push(o)});for(let o=n.length-1;o>=0;o--)s.push(n[o])}};var y={"@angular/fire/vertexai":"@angular/fire/ai","@angular/fire/vertexai-preview":"@angular/fire/ai","firebase/vertexai":"firebase/ai","firebase/vertexai-preview":"firebase/ai"},L={provideVertexAI:"provideAI",VertexAI:"AI",VertexAIError:"AIError",VertexAIErrorCode:"AIErrorCode",VertexAIModel:"AIModel",VertexAIInstances:"AIInstances",vertexAIInstance$:"AIInstance$",VertexAIModule:"AIModule"},V={VertexAIOptions:"the new AIOptions takes a backend instead of a location, rebuild the options by hand",getImagenModel:"the Imagen models were shut down in August 2026 and firebase 12.18 removed the API, move image generation to the Gemini image models through getGenerativeModel"},v="getVertexAI",C="getAI",T="VertexAIBackend",yr=new Set([...Object.keys(y),...Object.values(y)]);var vr=(t,e)=>{let{sourceFile:r}=t,s={edits:[],renamedLocalBindings:new Map,namespaceBindings:new Set,editedSpecifierTokenStarts:new Set,vertexImports:[],vertexExportSpecifiers:[],shadowedImports:[],starExportPositions:[],removedSymbols:[]};for(let i of r.statements)Mn(i,t,s,e);return s},Mn=(t,e,r,s)=>{var u;let{compiler:i,sourceFile:n}=e,o=i.isImportDeclaration(t),a=i.isExportDeclaration(t);if(!o&&!a)return;let c=t.moduleSpecifier,l=c&&i.isStringLiteral(c)&&y[c.text];if(!l)return;if(a&&(!t.exportClause||i.isNamespaceExport(t.exportClause))){r.starExportPositions.push(t.getStart(n));return}r.edits.push({start:c.getStart(n)+1,end:c.getEnd()-1,replacement:l});let m=o?(u=t.importClause)==null?void 0:u.namedBindings:t.exportClause;if(m&&i.isNamespaceImport(m)){s.has(m.name.text)?r.shadowedImports.push({position:m.getStart(n),name:m.name.text}):r.namespaceBindings.add(m.name.text);return}if(m&&(i.isNamedImports(m)||i.isNamedExports(m)))for(let g of m.elements)Xn(g,t,e,r,s)},Xn=(t,e,r,s,i)=>{var m;let{compiler:n,sourceFile:o}=r,a=(m=t.propertyName)!=null?m:t.name;if(n.isImportSpecifier(t)&&i.has(t.name.text)){s.shadowedImports.push({position:t.getStart(o),name:t.name.text});return}if(a.text===v){n.isImportSpecifier(t)&&n.isImportDeclaration(e)?s.vertexImports.push({element:t,statement:e,localName:t.name.text}):n.isExportSpecifier(t)&&s.vertexExportSpecifiers.push(t);return}if(V[a.text]!==void 0){s.removedSymbols.push({position:a.getStart(o),name:a.text});return}let c=L[a.text];if(!c)return;let l=n.isExportSpecifier(t)&&!t.propertyName;s.edits.push({start:a.getStart(o),end:a.getEnd(),replacement:l?`${c} as ${a.text}`:c}),s.editedSpecifierTokenStarts.add(a.getStart(o)),n.isImportSpecifier(t)&&!t.propertyName&&s.renamedLocalBindings.set(t.name.text,c)},Tr=(t,e,r,s)=>{let{compiler:i,sourceFile:n}=t,o={renamedNames:new Set(e.renamedLocalBindings.keys()),namespaceNames:e.namespaceBindings,vertexNames:new Set(r.keys())};P(i,n,a=>{let c=Zn(a,e.namespaceBindings,t);c&&e.edits.push(c);let l=Hn(a,e.namespaceBindings,t);if(l&&e.removedSymbols.push(l),Wn(a,e.namespaceBindings,t,s,o),i.isIdentifier(a)){Yn(a,r,t,s,o);let m=Jn(a,e,t);m&&e.edits.push(m)}})},Hn=(t,e,r)=>{let{compiler:s,sourceFile:i}=r;if(s.isPropertyAccessExpression(t)&&s.isIdentifier(t.expression)&&e.has(t.expression.text)&&V[t.name.text]!==void 0)return{position:t.name.getStart(i),name:t.name.text};if(s.isQualifiedName(t)&&s.isIdentifier(t.left)&&e.has(t.left.text)&&V[t.right.text]!==void 0)return{position:t.right.getStart(i),name:t.right.text}},Wn=(t,e,r,s,i)=>{let{compiler:n,sourceFile:o}=r;if(!n.isPropertyAccessExpression(t)||!n.isIdentifier(t.expression)||!e.has(t.expression.text)||t.name.text!==v)return;let a=t.parent;if(n.isCallExpression(a)&&a.expression===t){Or(a,{namespaceAccess:t},r,s,"namespace",i);return}s.unsupported.push({position:t.getStart(o),reason:`a use of ${t.expression.text}.getVertexAI that is not a direct call`,origin:"namespace"})},Yn=(t,e,r,s,i)=>{let{compiler:n,sourceFile:o}=r,a=e.get(t.text);if(!a||ve(r,t))return;let c=t.parent;if(n.isCallExpression(c)&&c.expression===t){Or(c,{binding:a},r,s,"binding",i);return}s.unsupported.push({position:t.getStart(o),reason:n.isExportSpecifier(c)?"a re-export of getVertexAI (rewriting it to getAI would silently change its callers' backend)":"a use of getVertexAI that is not a direct call (only direct calls can be rewritten safely)",origin:"binding"})},zn=(t,e,r)=>{let{compiler:s}=e;if(ve(e,t))return!1;if(r.renamedNames.has(t.text)||r.vertexNames.has(t.text))return!0;if(!r.namespaceNames.has(t.text))return!1;let i=t.parent;return s.isPropertyAccessExpression(i)&&i.expression===t?L[i.name.text]!==void 0||i.name.text===v:s.isQualifiedName(i)&&i.left===t?L[i.right.text]!==void 0:!1},Kn=(t,e,r)=>{let{compiler:s}=e,i=!1;return P(s,t,n=>{if(i)return!1;if(s.isIdentifier(n)&&zn(n,e,r))return i=!0,!1}),i},Qn=(t,e,r)=>{let{compiler:s,sourceFile:i}=e;if(!s.isObjectLiteralExpression(t))return{supported:!1};if(Kn(t,e,r))return{supported:!1,conflicting:!0};if(t.properties.length===0)return{supported:!0};let n=t.properties.length===1?t.properties[0]:void 0;return n&&s.isPropertyAssignment(n)&&s.isIdentifier(n.name)&&n.name.text==="location"?{supported:!0,locationText:n.initializer.getText(i)}:n&&s.isShorthandPropertyAssignment(n)&&n.name.text==="location"?{supported:!0,locationText:"location"}:{supported:!1}},Or=(t,e,r,s,i,n)=>{let{compiler:o,sourceFile:a}=r,c=t.arguments,l=c.some(o.isSpreadElement);if(c.length<=1&&!l){s.supportedCalls.push(oe({call:t},e));return}let m=!1;if(c.length===2&&!l){let u=Qn(c[1],r,n);if(u.supported){s.supportedCalls.push(be(oe({call:t},e),{locationText:u.locationText}));return}m=u.conflicting===!0}s.unsupported.push({position:t.getStart(a),reason:m?"a getVertexAI call whose options mention other symbols this migration rewrites (replacing both at once would conflict)":"a getVertexAI call whose arguments do not map onto getAI safely (only an optional app argument plus an optional literal `{ location }` object are rewritten)",origin:i})},Zn=(t,e,r)=>{let{compiler:s,sourceFile:i}=r;if(s.isPropertyAccessExpression(t)&&s.isIdentifier(t.expression)&&e.has(t.expression.text)&&L[t.name.text])return{start:t.name.getStart(i),end:t.name.getEnd(),replacement:L[t.name.text]};if(s.isQualifiedName(t)&&s.isIdentifier(t.left)&&e.has(t.left.text)&&L[t.right.text])return{start:t.right.getStart(i),end:t.right.getEnd(),replacement:L[t.right.text]}},Jn=(t,e,r)=>{let{compiler:s,sourceFile:i}=r,n=e.renamedLocalBindings.get(t.text);if(n===void 0)return;let o=t.getStart(i);if(e.editedSpecifierTokenStarts.has(o)||ve(r,t))return;let a=t.parent;if(s.isExportSpecifier(a)&&a.name===t&&!a.propertyName){let c=a.parent.parent;return s.isExportDeclaration(c)&&!c.moduleSpecifier?{start:o,end:t.getEnd(),replacement:`${n} as ${t.text}`}:void 0}return s.isShorthandPropertyAssignment(a)&&a.name===t?{start:t.getEnd(),end:t.getEnd(),replacement:`: ${n}`}:{start:o,end:t.getEnd(),replacement:n}},ve=(t,e)=>{let{compiler:r}=t,s=e.parent;return r.isImportSpecifier(s)&&(s.propertyName===e||s.name===e)||r.isBindingElement(s)&&(s.propertyName===e||s.name===e&&!s.propertyName)?!0:eo(t,e,s)},eo=(t,e,r)=>{let{compiler:s}=t,i=s.isPropertyAccessExpression(r)&&r.name===e||s.isQualifiedName(r)&&r.right===e,n=(s.isPropertyAssignment(r)||s.isPropertyDeclaration(r)||s.isPropertySignature(r)||s.isMethodDeclaration(r)||s.isGetAccessorDeclaration(r)||s.isSetAccessorDeclaration(r)||s.isEnumMember(r))&&r.name===e;return i||n};var to=t=>{let{compiler:e,sourceFile:r}=t,s=new Set;for(let i of r.statements)(e.isImportDeclaration(i)||e.isExportDeclaration(i))&&i.moduleSpecifier&&e.isStringLiteral(i.moduleSpecifier)&&y[i.moduleSpecifier.text]&&s.add(i);return s},ro=(t,e)=>{var i,n;let{compiler:r}=t,s=new Set;for(let o of e){if(!r.isImportDeclaration(o))continue;let a=(i=o.importClause)==null?void 0:i.namedBindings;if(a){if(r.isNamespaceImport(a)){s.add(a.name.text);continue}for(let c of a.elements){let l=((n=c.propertyName)!=null?n:c.name).text;(l===v||L[l]&&!c.propertyName)&&s.add(c.name.text)}}}return s},Cr=(t,e)=>{let{compiler:r}=t;if((r.isVariableDeclaration(e)||r.isParameter(e)||r.isBindingElement(e))&&r.isIdentifier(e.name)||(r.isFunctionDeclaration(e)||r.isFunctionExpression(e)||r.isClassDeclaration(e)||r.isClassExpression(e)||r.isInterfaceDeclaration(e)||r.isTypeAliasDeclaration(e)||r.isEnumDeclaration(e))&&e.name||r.isTypeParameterDeclaration(e)||r.isImportSpecifier(e)||r.isNamespaceImport(e)||r.isImportClause(e)&&e.name)return e.name.text},so=(t,e)=>{let{compiler:r}=t;if(!r.isImportSpecifier(e)||e.propertyName)return!1;let s=e;for(;s&&!r.isImportDeclaration(s);)s=s.parent;return!s||!r.isImportDeclaration(s)?!1:r.isStringLiteral(s.moduleSpecifier)&&yr.has(s.moduleSpecifier.text)},br=t=>{let{compiler:e,sourceFile:r}=t,s=to(t),i=ro(t,s),n=new Set;return i.size===0||P(e,r,o=>{if(s.has(o))return!1;let a=Cr(t,o);a&&i.has(a)&&n.add(a)}),n},Fr=t=>{let{compiler:e,sourceFile:r}=t,s=[];return P(e,r,i=>{let n=Cr(t,i);(n===C||n===T)&&!so(t,i)&&s.push({position:i.getStart(r),name:n})}),s};var Dr=(t,e,r,s)=>{let{sourceFile:i}=t,n=[],o=[],a=[],c=s.length>0&&e.vertexImports.length>0,l=r.unsupported.some(u=>u.origin==="binding")||c,m=new Set;for(let u of r.supportedCalls){if(u.binding&&l){a.push(u.call.getStart(i));continue}let g=u.namespaceAccess?`${u.namespaceAccess.expression.getText(i)}.${T}`:T;if(u.binding&&(m.add(u.binding.statement),u.binding.localName===v)){let d=u.call.expression;n.push({start:d.getStart(i),end:d.getEnd(),replacement:C})}if(u.namespaceAccess){let d=u.namespaceAccess.name;n.push({start:d.getStart(i),end:d.getEnd(),replacement:C})}n.push(...no(u,t,g)),o.push(u.call.getStart(i))}if(!l){let u=io(t),g=u.has(T);for(let d of e.vertexImports){let H=m.has(d.statement)&&!g;n.push(...oo(d,H,u.has(C),t)),H&&(g=!0)}}return{edits:n,callPositions:o,blockedCallPositions:a,injectionBlocked:c}},io=t=>{let{compiler:e,sourceFile:r}=t,s=new Set;for(let i of r.statements){if(!e.isImportDeclaration(i)||!i.importClause)continue;i.importClause.name&&s.add(i.importClause.name.text);let n=i.importClause.namedBindings;if(n)if(e.isNamespaceImport(n))s.add(n.name.text);else for(let o of n.elements)s.add(o.name.text)}return s},no=(t,e,r)=>{var a;let{sourceFile:s}=e,i=`{ backend: new ${r}(${(a=t.locationText)!=null?a:""}) }`,n=t.call.arguments;if(n.length===0)return[{start:t.call.getEnd()-1,end:t.call.getEnd()-1,replacement:`undefined, ${i}`}];if(n.length===1){let c=n[0];return[{start:c.getEnd(),end:c.getEnd(),replacement:`, ${i}`}]}let o=n[1];return[{start:o.getStart(s),end:o.getEnd(),replacement:i}]},oo=(t,e,r,s)=>{var u,g;let{compiler:i,sourceFile:n}=s,o=[],a=(u=t.statement.importClause)==null?void 0:u.namedBindings;if(!a||!i.isNamedImports(a))return o;let c=a.elements,l=t.element,m=(g=l.propertyName)!=null?g:l.name;if(!l.propertyName&&r){if(e)return[{start:l.getStart(n),end:l.getEnd(),replacement:T}];if(c.length===1)return[{start:l.getStart(n),end:l.getEnd(),replacement:""}];let d=c.indexOf(l);return d>0?[{start:c[d-1].getEnd(),end:l.getEnd(),replacement:""}]:[{start:l.getStart(n),end:c[1].getStart(n),replacement:""}]}return o.push({start:m.getStart(n),end:m.getEnd(),replacement:C}),e&&o.push({start:l.getEnd(),end:l.getEnd(),replacement:`, ${T}`}),o};var b="see the AngularFire v21 upgrade guide (docs/version-21-upgrade.md)",ao=t=>{let{sourceFile:e}=t,r=vr(t,br(t)),s=new Map;for(let a of r.vertexImports)s.set(a.localName,a);let i={supportedCalls:[],unsupported:[]};(r.renamedLocalBindings.size>0||r.namespaceBindings.size>0||s.size>0)&&Tr(t,r,s,i);for(let a of r.vertexExportSpecifiers)i.unsupported.push({position:a.getStart(e),reason:"a re-export of getVertexAI (rewriting it to getAI would silently change its callers' backend)",origin:"export"});let n=r.vertexImports.length>0?Fr(t):[],o=Dr(t,r,i,n);return{edits:r.edits.concat(o.edits),vertexCallPositions:o.callPositions,blockedCallPositions:o.blockedCallPositions,unsupportedVertexUsages:i.unsupported,shadowedImports:r.shadowedImports,injectionConflicts:o.injectionBlocked?n:[],starExportPositions:r.starExportPositions,removedSymbols:r.removedSymbols}},co=t=>[...t.vertexCallPositions.map(e=>({level:"info",position:e,text:"rewrote getVertexAI(...) to getAI(..., { backend: new VertexAIBackend(...) }) to keep the call on the Vertex AI backend"})),...t.unsupportedVertexUsages.map(e=>({level:"warn",position:e.position,text:`left ${e.reason}. Plain getAI() uses the Gemini Developer API backend, NOT Vertex AI. Migrate this site by hand, ${b}`})),...t.shadowedImports.map(e=>({level:"warn",position:e.position,text:`left the \`${e.name}\` import name and its usages unrenamed: this file also declares a local named \`${e.name}\`, and name-based rewriting cannot tell the two apart. The import path itself still moves to the new entry point, so the leftover name fails to compile there. Migrate this file by hand, ${b}`})),...t.injectionConflicts.map(e=>({level:"warn",position:e.position,text:`\`${e.name}\` is already bound here from a source other than AI Logic, so the backend-preserving rewrite cannot inject or reuse it. The file's getVertexAI code was left as is, and its import path still moves to the new entry point, so the leftover getVertexAI fails to compile there. Migrate it by hand, ${b}`})),...t.blockedCallPositions.map(e=>({level:"warn",position:e,text:t.injectionConflicts.length>0?"left a rewritable getVertexAI call unrewritten because this file binds getAI or VertexAIBackend from another source (see that warning). Every use of the file's named getVertexAI imports is kept together so the pieces stay consistent, migrate them by hand":"left a rewritable getVertexAI call unrewritten because another getVertexAI use in this file cannot be rewritten (see its own warning). Every use of the file's named getVertexAI imports is kept together so the pieces stay consistent, migrate them by hand"})),...t.starExportPositions.map(e=>({level:"warn",position:e,text:`left \`export *\` from an old Vertex AI entry point unmigrated: rewriting it would silently rename this file's re-exported public symbols. Re-export what you need by name from '@angular/fire/ai' instead, ${b}`})),...t.removedSymbols.map(e=>({level:"warn",position:e.position,text:`left \`${e.name}\`, which no longer exists in the new entry point (${V[e.name]}). The leftover name fails to compile, migrate it by hand, ${b}`}))],lo=(t,e,r,s,i)=>{let n={compiler:r,sourceFile:r.createSourceFile(s,i,r.ScriptTarget.Latest,!0)},o=n.sourceFile;if(o.parseDiagnostics&&o.parseDiagnostics.length>0)return e.logger.warn(`${s}: skipped, the file has syntax errors, so the Vertex AI -> AI Logic rewrite cannot run on it safely. Fix the syntax and re-run ng update, or migrate it by hand, ${b}`),!1;let a=ao(n);for(let l of co(a)){let m=n.sourceFile.getLineAndCharacterOfPosition(l.position).line+1;e.logger[l.level](`${s}:${m}: ${l.text}`)}if(a.edits.length===0)return!1;let c;try{c=uo(i,a.edits)}catch(l){return e.logger.warn(`${s}: the Vertex AI -> AI Logic rewrite was skipped for this file (${l}). Migrate it by hand, ${b}`),!1}return c===i?!1:(ne(t,s,c),!0)},uo=(t,e)=>{let r=e.slice().sort((s,i)=>i.start-s.start||i.end-s.end);for(let s=1;s<r.length;s++)if(r[s].end>r[s-1].start)throw new Error(`conflicting rewrite edits at offsets ${r[s].start} and ${r[s-1].start}`);return r.reduce((s,i)=>s.slice(0,i.start)+i.replacement+s.slice(i.end),t)},po=t=>Object.values(t.projects).map(e=>(e==null?void 0:e.sourceRoot)||(e==null?void 0:e.root)).filter(e=>typeof e=="string").map(e=>{let r=qr.posix.join("/",e);return r==="/"?r:r.replace(/\/+$/,"")}),fo=(t,e)=>t.endsWith(".ts")&&!t.endsWith(".d.ts")&&!t.split("/").includes("node_modules")&&e.some(r=>r==="/"||t===r||t.startsWith(r+"/")),Pr=(t,e,r)=>{let s=r!=null?r:Lr(),i=t.exists("angular.json")&&ye("angular.json",t);if(!(i!=null&&i.projects))return!1;let n=po(i);if(n.length===0)return!1;let o=!1;return t.visit(a=>{var l;if(!fo(a,n))return;let c=(l=t.read(a))==null?void 0:l.toString();if(!(!c||!Object.keys(y).some(m=>c.includes(m)))){if(!s){e.logger.warn(`${a} imports a removed Vertex AI entry point, but the Vertex AI -> AI Logic rewrite was skipped: the \`typescript\` package could not be resolved (it is an optional peer dependency of @angular/fire). Install typescript and re-run, or migrate by hand - see the v21 upgrade guide (docs/version-21-upgrade.md).`);return}o=lo(t,e,s,a,c)||o}}),o};var mo=t=>(e,r)=>{Nr(e,r)&&r.addTask(new Vr.NodePackageInstallTask);try{Pr(e,r,t==null?void 0:t.compiler)}catch(s){r.logger.warn(`Skipped the Vertex AI -> AI Logic source rewrite: ${s}. Any remaining @angular/fire/vertexai imports need a manual migration - see the v21 upgrade guide (docs/version-21-upgrade.md).`)}return e};0&&(module.exports={ngUpdate});
|
|
1
|
+
var Br=Object.create;var _=Object.defineProperty,Mr=Object.defineProperties,Xr=Object.getOwnPropertyDescriptor,Hr=Object.getOwnPropertyDescriptors,Wr=Object.getOwnPropertyNames,Ce=Object.getOwnPropertySymbols,Yr=Object.getPrototypeOf,Fe=Object.prototype.hasOwnProperty,zr=Object.prototype.propertyIsEnumerable;var be=(t,e,r)=>e in t?_(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,ce=(t,e)=>{for(var r in e||(e={}))Fe.call(e,r)&&be(t,r,e[r]);if(Ce)for(var r of Ce(e))zr.call(e,r)&&be(t,r,e[r]);return t},De=(t,e)=>Mr(t,Hr(e));var h=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),Kr=(t,e)=>{for(var r in e)_(t,r,{get:e[r],enumerable:!0})},Pe=(t,e,r,s)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of Wr(e))!Fe.call(t,i)&&i!==r&&_(t,i,{get:()=>e[i],enumerable:!(s=Xr(e,i))||s.enumerable});return t};var Qr=(t,e,r)=>(r=t!=null?Br(Yr(t)):{},Pe(e||!t||!t.__esModule?_(r,"default",{value:t,enumerable:!0}):r,t)),Zr=t=>Pe(_({},"__esModule",{value:!0}),t);var U=h((wo,qe)=>{"use strict";var Jr="2.0.0",es=Number.MAX_SAFE_INTEGER||9007199254740991,ts=16,rs=250,ss=["major","premajor","minor","preminor","patch","prepatch","prerelease"];qe.exports={MAX_LENGTH:256,MAX_SAFE_COMPONENT_LENGTH:ts,MAX_SAFE_BUILD_LENGTH:rs,MAX_SAFE_INTEGER:es,RELEASE_TYPES:ss,SEMVER_SPEC_VERSION:Jr,FLAG_INCLUDE_PRERELEASE:1,FLAG_LOOSE:2}});var B=h((yo,Ve)=>{"use strict";var is=typeof process=="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?(...t)=>console.error("SEMVER",...t):()=>{};Ve.exports=is});var P=h((w,ke)=>{"use strict";var{MAX_SAFE_COMPONENT_LENGTH:le,MAX_SAFE_BUILD_LENGTH:ns,MAX_LENGTH:os}=U(),as=B();w=ke.exports={};var cs=w.re=[],ls=w.safeRe=[],f=w.src=[],us=w.safeSrc=[],m=w.t={},ps=0,ue="[a-zA-Z0-9-]",fs=[["\\s",1],["\\d",os],[ue,ns]],ms=t=>{for(let[e,r]of fs)t=t.split(`${e}*`).join(`${e}{0,${r}}`).split(`${e}+`).join(`${e}{1,${r}}`);return t},E=(t,e,r)=>{let s=ms(e),i=ps++;as(t,i,e),m[t]=i,f[i]=e,us[i]=s,cs[i]=new RegExp(e,r?"g":void 0),ls[i]=new RegExp(s,r?"g":void 0)};E("NUMERICIDENTIFIER","0|[1-9]\\d*");E("NUMERICIDENTIFIERLOOSE","\\d+");E("NONNUMERICIDENTIFIER",`\\d*[a-zA-Z-]${ue}*`);E("MAINVERSION",`(${f[m.NUMERICIDENTIFIER]})\\.(${f[m.NUMERICIDENTIFIER]})\\.(${f[m.NUMERICIDENTIFIER]})`);E("MAINVERSIONLOOSE",`(${f[m.NUMERICIDENTIFIERLOOSE]})\\.(${f[m.NUMERICIDENTIFIERLOOSE]})\\.(${f[m.NUMERICIDENTIFIERLOOSE]})`);E("PRERELEASEIDENTIFIER",`(?:${f[m.NONNUMERICIDENTIFIER]}|${f[m.NUMERICIDENTIFIER]})`);E("PRERELEASEIDENTIFIERLOOSE",`(?:${f[m.NONNUMERICIDENTIFIER]}|${f[m.NUMERICIDENTIFIERLOOSE]})`);E("PRERELEASE",`(?:-(${f[m.PRERELEASEIDENTIFIER]}(?:\\.${f[m.PRERELEASEIDENTIFIER]})*))`);E("PRERELEASELOOSE",`(?:-?(${f[m.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${f[m.PRERELEASEIDENTIFIERLOOSE]})*))`);E("BUILDIDENTIFIER",`${ue}+`);E("BUILD",`(?:\\+(${f[m.BUILDIDENTIFIER]}(?:\\.${f[m.BUILDIDENTIFIER]})*))`);E("FULLPLAIN",`v?${f[m.MAINVERSION]}${f[m.PRERELEASE]}?${f[m.BUILD]}?`);E("FULL",`^${f[m.FULLPLAIN]}$`);E("LOOSEPLAIN",`[v=\\s]*${f[m.MAINVERSIONLOOSE]}${f[m.PRERELEASELOOSE]}?${f[m.BUILD]}?`);E("LOOSE",`^${f[m.LOOSEPLAIN]}$`);E("GTLT","((?:<|>)?=?)");E("XRANGEIDENTIFIERLOOSE",`${f[m.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`);E("XRANGEIDENTIFIER",`${f[m.NUMERICIDENTIFIER]}|x|X|\\*`);E("XRANGEPLAIN",`[v=\\s]*(${f[m.XRANGEIDENTIFIER]})(?:\\.(${f[m.XRANGEIDENTIFIER]})(?:\\.(${f[m.XRANGEIDENTIFIER]})(?:${f[m.PRERELEASE]})?${f[m.BUILD]}?)?)?`);E("XRANGEPLAINLOOSE",`[v=\\s]*(${f[m.XRANGEIDENTIFIERLOOSE]})(?:\\.(${f[m.XRANGEIDENTIFIERLOOSE]})(?:\\.(${f[m.XRANGEIDENTIFIERLOOSE]})(?:${f[m.PRERELEASELOOSE]})?${f[m.BUILD]}?)?)?`);E("XRANGE",`^${f[m.GTLT]}\\s*${f[m.XRANGEPLAIN]}$`);E("XRANGELOOSE",`^${f[m.GTLT]}\\s*${f[m.XRANGEPLAINLOOSE]}$`);E("COERCEPLAIN",`(^|[^\\d])(\\d{1,${le}})(?:\\.(\\d{1,${le}}))?(?:\\.(\\d{1,${le}}))?`);E("COERCE",`${f[m.COERCEPLAIN]}(?:$|[^\\d])`);E("COERCEFULL",f[m.COERCEPLAIN]+`(?:${f[m.PRERELEASE]})?(?:${f[m.BUILD]})?(?:$|[^\\d])`);E("COERCERTL",f[m.COERCE],!0);E("COERCERTLFULL",f[m.COERCEFULL],!0);E("LONETILDE","(?:~>?)");E("TILDETRIM",`(\\s*)${f[m.LONETILDE]}\\s+`,!0);w.tildeTrimReplace="$1~";E("TILDE",`^${f[m.LONETILDE]}${f[m.XRANGEPLAIN]}$`);E("TILDELOOSE",`^${f[m.LONETILDE]}${f[m.XRANGEPLAINLOOSE]}$`);E("LONECARET","(?:\\^)");E("CARETTRIM",`(\\s*)${f[m.LONECARET]}\\s+`,!0);w.caretTrimReplace="$1^";E("CARET",`^${f[m.LONECARET]}${f[m.XRANGEPLAIN]}$`);E("CARETLOOSE",`^${f[m.LONECARET]}${f[m.XRANGEPLAINLOOSE]}$`);E("COMPARATORLOOSE",`^${f[m.GTLT]}\\s*(${f[m.LOOSEPLAIN]})$|^$`);E("COMPARATOR",`^${f[m.GTLT]}\\s*(${f[m.FULLPLAIN]})$|^$`);E("COMPARATORTRIM",`(\\s*)${f[m.GTLT]}\\s*(${f[m.LOOSEPLAIN]}|${f[m.XRANGEPLAIN]})`,!0);w.comparatorTrimReplace="$1$2$3";E("HYPHENRANGE",`^\\s*(${f[m.XRANGEPLAIN]})\\s+-\\s+(${f[m.XRANGEPLAIN]})\\s*$`);E("HYPHENRANGELOOSE",`^\\s*(${f[m.XRANGEPLAINLOOSE]})\\s+-\\s+(${f[m.XRANGEPLAINLOOSE]})\\s*$`);E("STAR","(<|>)?=?\\s*\\*");E("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$");E("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")});var z=h((vo,je)=>{"use strict";var ds=Object.freeze({loose:!0}),hs=Object.freeze({}),Es=t=>t?typeof t!="object"?ds:t:hs;je.exports=Es});var pe=h((To,Ue)=>{"use strict";var Ge=/^[0-9]+$/,_e=(t,e)=>{if(typeof t=="number"&&typeof e=="number")return t===e?0:t<e?-1:1;let r=Ge.test(t),s=Ge.test(e);return r&&s&&(t=+t,e=+e),t===e?0:r&&!s?-1:s&&!r?1:t<e?-1:1},gs=(t,e)=>_e(e,t);Ue.exports={compareIdentifiers:_e,rcompareIdentifiers:gs}});var x=h((Oo,Me)=>{"use strict";var K=B(),{MAX_LENGTH:Be,MAX_SAFE_INTEGER:Q}=U(),{safeRe:Z,t:J}=P(),Is=z(),{compareIdentifiers:fe}=pe(),me=class t{constructor(e,r){if(r=Is(r),e instanceof t){if(e.loose===!!r.loose&&e.includePrerelease===!!r.includePrerelease)return e;e=e.version}else if(typeof e!="string")throw new TypeError(`Invalid version. Must be a string. Got type "${typeof e}".`);if(e.length>Be)throw new TypeError(`version is longer than ${Be} characters`);K("SemVer",e,r),this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease;let s=e.trim().match(r.loose?Z[J.LOOSE]:Z[J.FULL]);if(!s)throw new TypeError(`Invalid Version: ${e}`);if(this.raw=e,this.major=+s[1],this.minor=+s[2],this.patch=+s[3],this.major>Q||this.major<0)throw new TypeError("Invalid major version");if(this.minor>Q||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>Q||this.patch<0)throw new TypeError("Invalid patch version");s[4]?this.prerelease=s[4].split(".").map(i=>{if(/^[0-9]+$/.test(i)){let n=+i;if(n>=0&&n<Q)return n}return i}):this.prerelease=[],this.build=s[5]?s[5].split("."):[],this.format()}format(){return this.version=`${this.major}.${this.minor}.${this.patch}`,this.prerelease.length&&(this.version+=`-${this.prerelease.join(".")}`),this.version}toString(){return this.version}compare(e){if(K("SemVer.compare",this.version,this.options,e),!(e instanceof t)){if(typeof e=="string"&&e===this.version)return 0;e=new t(e,this.options)}return e.version===this.version?0:this.compareMain(e)||this.comparePre(e)}compareMain(e){return e instanceof t||(e=new t(e,this.options)),this.major<e.major?-1:this.major>e.major?1:this.minor<e.minor?-1:this.minor>e.minor?1:this.patch<e.patch?-1:this.patch>e.patch?1:0}comparePre(e){if(e instanceof t||(e=new t(e,this.options)),this.prerelease.length&&!e.prerelease.length)return-1;if(!this.prerelease.length&&e.prerelease.length)return 1;if(!this.prerelease.length&&!e.prerelease.length)return 0;let r=0;do{let s=this.prerelease[r],i=e.prerelease[r];if(K("prerelease compare",r,s,i),s===void 0&&i===void 0)return 0;if(i===void 0)return 1;if(s===void 0)return-1;if(s===i)continue;return fe(s,i)}while(++r)}compareBuild(e){e instanceof t||(e=new t(e,this.options));let r=0;do{let s=this.build[r],i=e.build[r];if(K("build compare",r,s,i),s===void 0&&i===void 0)return 0;if(i===void 0)return 1;if(s===void 0)return-1;if(s===i)continue;return fe(s,i)}while(++r)}inc(e,r,s){if(e.startsWith("pre")){if(!r&&s===!1)throw new Error("invalid increment argument: identifier is empty");if(r){let i=`-${r}`.match(this.options.loose?Z[J.PRERELEASELOOSE]:Z[J.PRERELEASE]);if(!i||i[1]!==r)throw new Error(`invalid identifier: ${r}`)}}switch(e){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",r,s);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",r,s);break;case"prepatch":this.prerelease.length=0,this.inc("patch",r,s),this.inc("pre",r,s);break;case"prerelease":this.prerelease.length===0&&this.inc("patch",r,s),this.inc("pre",r,s);break;case"release":if(this.prerelease.length===0)throw new Error(`version ${this.raw} is not a prerelease`);this.prerelease.length=0;break;case"major":(this.minor!==0||this.patch!==0||this.prerelease.length===0)&&this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":(this.patch!==0||this.prerelease.length===0)&&this.minor++,this.patch=0,this.prerelease=[];break;case"patch":this.prerelease.length===0&&this.patch++,this.prerelease=[];break;case"pre":{let i=Number(s)?1:0;if(this.prerelease.length===0)this.prerelease=[i];else{let n=this.prerelease.length;for(;--n>=0;)typeof this.prerelease[n]=="number"&&(this.prerelease[n]++,n=-2);if(n===-1){if(r===this.prerelease.join(".")&&s===!1)throw new Error("invalid increment argument: identifier already exists");this.prerelease.push(i)}}if(r){let n=[r,i];s===!1&&(n=[r]),fe(this.prerelease[0],r)===0?isNaN(this.prerelease[1])&&(this.prerelease=n):this.prerelease=n}break}default:throw new Error(`invalid increment argument: ${e}`)}return this.raw=this.format(),this.build.length&&(this.raw+=`+${this.build.join(".")}`),this}};Me.exports=me});var F=h((Co,He)=>{"use strict";var Xe=x(),xs=(t,e,r=!1)=>{if(t instanceof Xe)return t;try{return new Xe(t,e)}catch(s){if(!r)return null;throw s}};He.exports=xs});var Ye=h((bo,We)=>{"use strict";var Ss=F(),$s=(t,e)=>{let r=Ss(t,e);return r?r.version:null};We.exports=$s});var Ke=h((Fo,ze)=>{"use strict";var Rs=F(),As=(t,e)=>{let r=Rs(t.trim().replace(/^[=v]+/,""),e);return r?r.version:null};ze.exports=As});var Je=h((Do,Ze)=>{"use strict";var Qe=x(),Ns=(t,e,r,s,i)=>{typeof r=="string"&&(i=s,s=r,r=void 0);try{return new Qe(t instanceof Qe?t.version:t,r).inc(e,s,i).version}catch(n){return null}};Ze.exports=Ns});var rt=h((Po,tt)=>{"use strict";var et=F(),Ls=(t,e)=>{let r=et(t,null,!0),s=et(e,null,!0),i=r.compare(s);if(i===0)return null;let n=i>0,o=n?r:s,a=n?s:r,c=!!o.prerelease.length;if(!!a.prerelease.length&&!c){if(!a.patch&&!a.minor)return"major";if(a.compareMain(o)===0)return a.minor&&!a.patch?"minor":"patch"}let u=c?"pre":"";return r.major!==s.major?u+"major":r.minor!==s.minor?u+"minor":r.patch!==s.patch?u+"patch":"prerelease"};tt.exports=Ls});var it=h((qo,st)=>{"use strict";var ws=x(),ys=(t,e)=>new ws(t,e).major;st.exports=ys});var ot=h((Vo,nt)=>{"use strict";var vs=x(),Ts=(t,e)=>new vs(t,e).minor;nt.exports=Ts});var ct=h((ko,at)=>{"use strict";var Os=x(),Cs=(t,e)=>new Os(t,e).patch;at.exports=Cs});var ut=h((jo,lt)=>{"use strict";var bs=F(),Fs=(t,e)=>{let r=bs(t,e);return r&&r.prerelease.length?r.prerelease:null};lt.exports=Fs});var A=h((Go,ft)=>{"use strict";var pt=x(),Ds=(t,e,r)=>new pt(t,r).compare(new pt(e,r));ft.exports=Ds});var dt=h((_o,mt)=>{"use strict";var Ps=A(),qs=(t,e,r)=>Ps(e,t,r);mt.exports=qs});var Et=h((Uo,ht)=>{"use strict";var Vs=A(),ks=(t,e)=>Vs(t,e,!0);ht.exports=ks});var ee=h((Bo,It)=>{"use strict";var gt=x(),js=(t,e,r)=>{let s=new gt(t,r),i=new gt(e,r);return s.compare(i)||s.compareBuild(i)};It.exports=js});var St=h((Mo,xt)=>{"use strict";var Gs=ee(),_s=(t,e)=>t.sort((r,s)=>Gs(r,s,e));xt.exports=_s});var Rt=h((Xo,$t)=>{"use strict";var Us=ee(),Bs=(t,e)=>t.sort((r,s)=>Us(s,r,e));$t.exports=Bs});var M=h((Ho,At)=>{"use strict";var Ms=A(),Xs=(t,e,r)=>Ms(t,e,r)>0;At.exports=Xs});var te=h((Wo,Nt)=>{"use strict";var Hs=A(),Ws=(t,e,r)=>Hs(t,e,r)<0;Nt.exports=Ws});var de=h((Yo,Lt)=>{"use strict";var Ys=A(),zs=(t,e,r)=>Ys(t,e,r)===0;Lt.exports=zs});var he=h((zo,wt)=>{"use strict";var Ks=A(),Qs=(t,e,r)=>Ks(t,e,r)!==0;wt.exports=Qs});var re=h((Ko,yt)=>{"use strict";var Zs=A(),Js=(t,e,r)=>Zs(t,e,r)>=0;yt.exports=Js});var se=h((Qo,vt)=>{"use strict";var ei=A(),ti=(t,e,r)=>ei(t,e,r)<=0;vt.exports=ti});var Ee=h((Zo,Tt)=>{"use strict";var ri=de(),si=he(),ii=M(),ni=re(),oi=te(),ai=se(),ci=(t,e,r,s)=>{switch(e){case"===":return typeof t=="object"&&(t=t.version),typeof r=="object"&&(r=r.version),t===r;case"!==":return typeof t=="object"&&(t=t.version),typeof r=="object"&&(r=r.version),t!==r;case"":case"=":case"==":return ri(t,r,s);case"!=":return si(t,r,s);case">":return ii(t,r,s);case">=":return ni(t,r,s);case"<":return oi(t,r,s);case"<=":return ai(t,r,s);default:throw new TypeError(`Invalid operator: ${e}`)}};Tt.exports=ci});var Ct=h((Jo,Ot)=>{"use strict";var li=x(),ui=F(),{safeRe:ie,t:ne}=P(),pi=(t,e)=>{if(t instanceof li)return t;if(typeof t=="number"&&(t=String(t)),typeof t!="string")return null;e=e||{};let r=null;if(!e.rtl)r=t.match(e.includePrerelease?ie[ne.COERCEFULL]:ie[ne.COERCE]);else{let c=e.includePrerelease?ie[ne.COERCERTLFULL]:ie[ne.COERCERTL],l;for(;(l=c.exec(t))&&(!r||r.index+r[0].length!==t.length);)(!r||l.index+l[0].length!==r.index+r[0].length)&&(r=l),c.lastIndex=l.index+l[1].length+l[2].length;c.lastIndex=-1}if(r===null)return null;let s=r[2],i=r[3]||"0",n=r[4]||"0",o=e.includePrerelease&&r[5]?`-${r[5]}`:"",a=e.includePrerelease&&r[6]?`+${r[6]}`:"";return ui(`${s}.${i}.${n}${o}${a}`,e)};Ot.exports=pi});var Ft=h((ea,bt)=>{"use strict";var ge=class{constructor(){this.max=1e3,this.map=new Map}get(e){let r=this.map.get(e);if(r!==void 0)return this.map.delete(e),this.map.set(e,r),r}delete(e){return this.map.delete(e)}set(e,r){if(!this.delete(e)&&r!==void 0){if(this.map.size>=this.max){let i=this.map.keys().next().value;this.delete(i)}this.map.set(e,r)}return this}};bt.exports=ge});var N=h((ta,Vt)=>{"use strict";var fi=/\s+/g,Ie=class t{constructor(e,r){if(r=di(r),e instanceof t)return e.loose===!!r.loose&&e.includePrerelease===!!r.includePrerelease?e:new t(e.raw,r);if(e instanceof xe)return this.raw=e.value,this.set=[[e]],this.formatted=void 0,this;if(this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease,this.raw=e.trim().replace(fi," "),this.set=this.raw.split("||").map(s=>this.parseRange(s.trim())).filter(s=>s.length),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${this.raw}`);if(this.set.length>1){let s=this.set[0];if(this.set=this.set.filter(i=>!Pt(i[0])),this.set.length===0)this.set=[s];else if(this.set.length>1){for(let i of this.set)if(i.length===1&&$i(i[0])){this.set=[i];break}}}this.formatted=void 0}get range(){if(this.formatted===void 0){this.formatted="";for(let e=0;e<this.set.length;e++){e>0&&(this.formatted+="||");let r=this.set[e];for(let s=0;s<r.length;s++)s>0&&(this.formatted+=" "),this.formatted+=r[s].toString().trim()}}return this.formatted}format(){return this.range}toString(){return this.range}parseRange(e){let s=((this.options.includePrerelease&&xi)|(this.options.loose&&Si))+":"+e,i=Dt.get(s);if(i)return i;let n=this.options.loose,o=n?$[S.HYPHENRANGELOOSE]:$[S.HYPHENRANGE];e=e.replace(o,Ci(this.options.includePrerelease)),I("hyphen replace",e),e=e.replace($[S.COMPARATORTRIM],Ei),I("comparator trim",e),e=e.replace($[S.TILDETRIM],gi),I("tilde trim",e),e=e.replace($[S.CARETTRIM],Ii),I("caret trim",e);let a=e.split(" ").map(d=>Ri(d,this.options)).join(" ").split(/\s+/).map(d=>Oi(d,this.options));n&&(a=a.filter(d=>(I("loose invalid filter",d,this.options),!!d.match($[S.COMPARATORLOOSE])))),I("range list",a);let c=new Map,l=a.map(d=>new xe(d,this.options));for(let d of l){if(Pt(d))return[d];c.set(d.value,d)}c.size>1&&c.has("")&&c.delete("");let u=[...c.values()];return Dt.set(s,u),u}intersects(e,r){if(!(e instanceof t))throw new TypeError("a Range is required");return this.set.some(s=>qt(s,r)&&e.set.some(i=>qt(i,r)&&s.every(n=>i.every(o=>n.intersects(o,r)))))}test(e){if(!e)return!1;if(typeof e=="string")try{e=new hi(e,this.options)}catch(r){return!1}for(let r=0;r<this.set.length;r++)if(bi(this.set[r],e,this.options))return!0;return!1}};Vt.exports=Ie;var mi=Ft(),Dt=new mi,di=z(),xe=X(),I=B(),hi=x(),{safeRe:$,t:S,comparatorTrimReplace:Ei,tildeTrimReplace:gi,caretTrimReplace:Ii}=P(),{FLAG_INCLUDE_PRERELEASE:xi,FLAG_LOOSE:Si}=U(),Pt=t=>t.value==="<0.0.0-0",$i=t=>t.value==="",qt=(t,e)=>{let r=!0,s=t.slice(),i=s.pop();for(;r&&s.length;)r=s.every(n=>i.intersects(n,e)),i=s.pop();return r},Ri=(t,e)=>(t=t.replace($[S.BUILD],""),I("comp",t,e),t=Li(t,e),I("caret",t),t=Ai(t,e),I("tildes",t),t=yi(t,e),I("xrange",t),t=Ti(t,e),I("stars",t),t),R=t=>!t||t.toLowerCase()==="x"||t==="*",Ai=(t,e)=>t.trim().split(/\s+/).map(r=>Ni(r,e)).join(" "),Ni=(t,e)=>{let r=e.loose?$[S.TILDELOOSE]:$[S.TILDE];return t.replace(r,(s,i,n,o,a)=>{I("tilde",t,s,i,n,o,a);let c;return R(i)?c="":R(n)?c=`>=${i}.0.0 <${+i+1}.0.0-0`:R(o)?c=`>=${i}.${n}.0 <${i}.${+n+1}.0-0`:a?(I("replaceTilde pr",a),c=`>=${i}.${n}.${o}-${a} <${i}.${+n+1}.0-0`):c=`>=${i}.${n}.${o} <${i}.${+n+1}.0-0`,I("tilde return",c),c})},Li=(t,e)=>t.trim().split(/\s+/).map(r=>wi(r,e)).join(" "),wi=(t,e)=>{I("caret",t,e);let r=e.loose?$[S.CARETLOOSE]:$[S.CARET],s=e.includePrerelease?"-0":"";return t.replace(r,(i,n,o,a,c)=>{I("caret",t,i,n,o,a,c);let l;return R(n)?l="":R(o)?l=`>=${n}.0.0${s} <${+n+1}.0.0-0`:R(a)?n==="0"?l=`>=${n}.${o}.0${s} <${n}.${+o+1}.0-0`:l=`>=${n}.${o}.0${s} <${+n+1}.0.0-0`:c?(I("replaceCaret pr",c),n==="0"?o==="0"?l=`>=${n}.${o}.${a}-${c} <${n}.${o}.${+a+1}-0`:l=`>=${n}.${o}.${a}-${c} <${n}.${+o+1}.0-0`:l=`>=${n}.${o}.${a}-${c} <${+n+1}.0.0-0`):(I("no pr"),n==="0"?o==="0"?l=`>=${n}.${o}.${a}${s} <${n}.${o}.${+a+1}-0`:l=`>=${n}.${o}.${a}${s} <${n}.${+o+1}.0-0`:l=`>=${n}.${o}.${a} <${+n+1}.0.0-0`),I("caret return",l),l})},yi=(t,e)=>(I("replaceXRanges",t,e),t.split(/\s+/).map(r=>vi(r,e)).join(" ")),vi=(t,e)=>{t=t.trim();let r=e.loose?$[S.XRANGELOOSE]:$[S.XRANGE];return t.replace(r,(s,i,n,o,a,c)=>{I("xRange",t,s,i,n,o,a,c);let l=R(n),u=l||R(o),d=u||R(a),g=d;return i==="="&&g&&(i=""),c=e.includePrerelease?"-0":"",l?i===">"||i==="<"?s="<0.0.0-0":s="*":i&&g?(u&&(o=0),a=0,i===">"?(i=">=",u?(n=+n+1,o=0,a=0):(o=+o+1,a=0)):i==="<="&&(i="<",u?n=+n+1:o=+o+1),i==="<"&&(c="-0"),s=`${i+n}.${o}.${a}${c}`):u?s=`>=${n}.0.0${c} <${+n+1}.0.0-0`:d&&(s=`>=${n}.${o}.0${c} <${n}.${+o+1}.0-0`),I("xRange return",s),s})},Ti=(t,e)=>(I("replaceStars",t,e),t.trim().replace($[S.STAR],"")),Oi=(t,e)=>(I("replaceGTE0",t,e),t.trim().replace($[e.includePrerelease?S.GTE0PRE:S.GTE0],"")),Ci=t=>(e,r,s,i,n,o,a,c,l,u,d,g)=>(R(s)?r="":R(i)?r=`>=${s}.0.0${t?"-0":""}`:R(n)?r=`>=${s}.${i}.0${t?"-0":""}`:o?r=`>=${r}`:r=`>=${r}${t?"-0":""}`,R(l)?c="":R(u)?c=`<${+l+1}.0.0-0`:R(d)?c=`<${l}.${+u+1}.0-0`:g?c=`<=${l}.${u}.${d}-${g}`:t?c=`<${l}.${u}.${+d+1}-0`:c=`<=${c}`,`${r} ${c}`.trim()),bi=(t,e,r)=>{for(let s=0;s<t.length;s++)if(!t[s].test(e))return!1;if(e.prerelease.length&&!r.includePrerelease){for(let s=0;s<t.length;s++)if(I(t[s].semver),t[s].semver!==xe.ANY&&t[s].semver.prerelease.length>0){let i=t[s].semver;if(i.major===e.major&&i.minor===e.minor&&i.patch===e.patch)return!0}return!1}return!0}});var X=h((ra,Bt)=>{"use strict";var H=Symbol("SemVer ANY"),Re=class t{static get ANY(){return H}constructor(e,r){if(r=kt(r),e instanceof t){if(e.loose===!!r.loose)return e;e=e.value}e=e.trim().split(/\s+/).join(" "),$e("comparator",e,r),this.options=r,this.loose=!!r.loose,this.parse(e),this.semver===H?this.value="":this.value=this.operator+this.semver.version,$e("comp",this)}parse(e){let r=this.options.loose?jt[Gt.COMPARATORLOOSE]:jt[Gt.COMPARATOR],s=e.match(r);if(!s)throw new TypeError(`Invalid comparator: ${e}`);this.operator=s[1]!==void 0?s[1]:"",this.operator==="="&&(this.operator=""),s[2]?this.semver=new _t(s[2],this.options.loose):this.semver=H}toString(){return this.value}test(e){if($e("Comparator.test",e,this.options.loose),this.semver===H||e===H)return!0;if(typeof e=="string")try{e=new _t(e,this.options)}catch(r){return!1}return Se(e,this.operator,this.semver,this.options)}intersects(e,r){if(!(e instanceof t))throw new TypeError("a Comparator is required");return this.operator===""?this.value===""?!0:new Ut(e.value,r).test(this.value):e.operator===""?e.value===""?!0:new Ut(this.value,r).test(e.semver):(r=kt(r),r.includePrerelease&&(this.value==="<0.0.0-0"||e.value==="<0.0.0-0")||!r.includePrerelease&&(this.value.startsWith("<0.0.0")||e.value.startsWith("<0.0.0"))?!1:!!(this.operator.startsWith(">")&&e.operator.startsWith(">")||this.operator.startsWith("<")&&e.operator.startsWith("<")||this.semver.version===e.semver.version&&this.operator.includes("=")&&e.operator.includes("=")||Se(this.semver,"<",e.semver,r)&&this.operator.startsWith(">")&&e.operator.startsWith("<")||Se(this.semver,">",e.semver,r)&&this.operator.startsWith("<")&&e.operator.startsWith(">")))}};Bt.exports=Re;var kt=z(),{safeRe:jt,t:Gt}=P(),Se=Ee(),$e=B(),_t=x(),Ut=N()});var W=h((sa,Mt)=>{"use strict";var Fi=N(),Di=(t,e,r)=>{try{e=new Fi(e,r)}catch(s){return!1}return e.test(t)};Mt.exports=Di});var Ht=h((ia,Xt)=>{"use strict";var Pi=N(),qi=(t,e)=>new Pi(t,e).set.map(r=>r.map(s=>s.value).join(" ").trim().split(" "));Xt.exports=qi});var Yt=h((na,Wt)=>{"use strict";var Vi=x(),ki=N(),ji=(t,e,r)=>{let s=null,i=null,n=null;try{n=new ki(e,r)}catch(o){return null}return t.forEach(o=>{n.test(o)&&(!s||i.compare(o)===-1)&&(s=o,i=new Vi(s,r))}),s};Wt.exports=ji});var Kt=h((oa,zt)=>{"use strict";var Gi=x(),_i=N(),Ui=(t,e,r)=>{let s=null,i=null,n=null;try{n=new _i(e,r)}catch(o){return null}return t.forEach(o=>{n.test(o)&&(!s||i.compare(o)===1)&&(s=o,i=new Gi(s,r))}),s};zt.exports=Ui});var Jt=h((aa,Zt)=>{"use strict";var Ae=x(),Bi=N(),Qt=M(),Mi=(t,e)=>{t=new Bi(t,e);let r=new Ae("0.0.0");if(t.test(r)||(r=new Ae("0.0.0-0"),t.test(r)))return r;r=null;for(let s=0;s<t.set.length;++s){let i=t.set[s],n=null;i.forEach(o=>{let a=new Ae(o.semver.version);switch(o.operator){case">":a.prerelease.length===0?a.patch++:a.prerelease.push(0),a.raw=a.format();case"":case">=":(!n||Qt(a,n))&&(n=a);break;case"<":case"<=":break;default:throw new Error(`Unexpected operation: ${o.operator}`)}}),n&&(!r||Qt(r,n))&&(r=n)}return r&&t.test(r)?r:null};Zt.exports=Mi});var tr=h((ca,er)=>{"use strict";var Xi=N(),Hi=(t,e)=>{try{return new Xi(t,e).range||"*"}catch(r){return null}};er.exports=Hi});var oe=h((la,nr)=>{"use strict";var Wi=x(),ir=X(),{ANY:Yi}=ir,zi=N(),Ki=W(),rr=M(),sr=te(),Qi=se(),Zi=re(),Ji=(t,e,r,s)=>{t=new Wi(t,s),e=new zi(e,s);let i,n,o,a,c;switch(r){case">":i=rr,n=Qi,o=sr,a=">",c=">=";break;case"<":i=sr,n=Zi,o=rr,a="<",c="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(Ki(t,e,s))return!1;for(let l=0;l<e.set.length;++l){let u=e.set[l],d=null,g=null;if(u.forEach(p=>{p.semver===Yi&&(p=new ir(">=0.0.0")),d=d||p,g=g||p,i(p.semver,d.semver,s)?d=p:o(p.semver,g.semver,s)&&(g=p)}),d.operator===a||d.operator===c||(!g.operator||g.operator===a)&&n(t,g.semver))return!1;if(g.operator===c&&o(t,g.semver))return!1}return!0};nr.exports=Ji});var ar=h((ua,or)=>{"use strict";var en=oe(),tn=(t,e,r)=>en(t,e,">",r);or.exports=tn});var lr=h((pa,cr)=>{"use strict";var rn=oe(),sn=(t,e,r)=>rn(t,e,"<",r);cr.exports=sn});var fr=h((fa,pr)=>{"use strict";var ur=N(),nn=(t,e,r)=>(t=new ur(t,r),e=new ur(e,r),t.intersects(e,r));pr.exports=nn});var dr=h((ma,mr)=>{"use strict";var on=W(),an=A();mr.exports=(t,e,r)=>{let s=[],i=null,n=null,o=t.sort((u,d)=>an(u,d,r));for(let u of o)on(u,e,r)?(n=u,i||(i=u)):(n&&s.push([i,n]),n=null,i=null);i&&s.push([i,null]);let a=[];for(let[u,d]of s)u===d?a.push(u):!d&&u===o[0]?a.push("*"):d?u===o[0]?a.push(`<=${d}`):a.push(`${u} - ${d}`):a.push(`>=${u}`);let c=a.join(" || "),l=typeof e.raw=="string"?e.raw:String(e);return c.length<l.length?c:e}});var Sr=h((da,xr)=>{"use strict";var hr=N(),Le=X(),{ANY:Ne}=Le,Y=W(),we=A(),cn=(t,e,r={})=>{if(t===e)return!0;t=new hr(t,r),e=new hr(e,r);let s=!1;e:for(let i of t.set){for(let n of e.set){let o=un(i,n,r);if(s=s||o!==null,o)continue e}if(s)return!1}return!0},ln=[new Le(">=0.0.0-0")],Er=[new Le(">=0.0.0")],un=(t,e,r)=>{if(t===e)return!0;if(t.length===1&&t[0].semver===Ne){if(e.length===1&&e[0].semver===Ne)return!0;r.includePrerelease?t=ln:t=Er}if(e.length===1&&e[0].semver===Ne){if(r.includePrerelease)return!0;e=Er}let s=new Set,i,n;for(let p of t)p.operator===">"||p.operator===">="?i=gr(i,p,r):p.operator==="<"||p.operator==="<="?n=Ir(n,p,r):s.add(p.semver);if(s.size>1)return null;let o;if(i&&n){if(o=we(i.semver,n.semver,r),o>0)return null;if(o===0&&(i.operator!==">="||n.operator!=="<="))return null}for(let p of s){if(i&&!Y(p,String(i),r)||n&&!Y(p,String(n),r))return null;for(let b of e)if(!Y(p,String(b),r))return!1;return!0}let a,c,l,u,d=n&&!r.includePrerelease&&n.semver.prerelease.length?n.semver:!1,g=i&&!r.includePrerelease&&i.semver.prerelease.length?i.semver:!1;d&&d.prerelease.length===1&&n.operator==="<"&&d.prerelease[0]===0&&(d=!1);for(let p of e){if(u=u||p.operator===">"||p.operator===">=",l=l||p.operator==="<"||p.operator==="<=",i){if(g&&p.semver.prerelease&&p.semver.prerelease.length&&p.semver.major===g.major&&p.semver.minor===g.minor&&p.semver.patch===g.patch&&(g=!1),p.operator===">"||p.operator===">="){if(a=gr(i,p,r),a===p&&a!==i)return!1}else if(i.operator===">="&&!Y(i.semver,String(p),r))return!1}if(n){if(d&&p.semver.prerelease&&p.semver.prerelease.length&&p.semver.major===d.major&&p.semver.minor===d.minor&&p.semver.patch===d.patch&&(d=!1),p.operator==="<"||p.operator==="<="){if(c=Ir(n,p,r),c===p&&c!==n)return!1}else if(n.operator==="<="&&!Y(n.semver,String(p),r))return!1}if(!p.operator&&(n||i)&&o!==0)return!1}return!(i&&l&&!n&&o!==0||n&&u&&!i&&o!==0||g||d)},gr=(t,e,r)=>{if(!t)return e;let s=we(t.semver,e.semver,r);return s>0?t:s<0||e.operator===">"&&t.operator===">="?e:t},Ir=(t,e,r)=>{if(!t)return e;let s=we(t.semver,e.semver,r);return s<0?t:s>0||e.operator==="<"&&t.operator==="<="?e:t};xr.exports=cn});var Nr=h((ha,Ar)=>{"use strict";var ye=P(),$r=U(),pn=x(),Rr=pe(),fn=F(),mn=Ye(),dn=Ke(),hn=Je(),En=rt(),gn=it(),In=ot(),xn=ct(),Sn=ut(),$n=A(),Rn=dt(),An=Et(),Nn=ee(),Ln=St(),wn=Rt(),yn=M(),vn=te(),Tn=de(),On=he(),Cn=re(),bn=se(),Fn=Ee(),Dn=Ct(),Pn=X(),qn=N(),Vn=W(),kn=Ht(),jn=Yt(),Gn=Kt(),_n=Jt(),Un=tr(),Bn=oe(),Mn=ar(),Xn=lr(),Hn=fr(),Wn=dr(),Yn=Sr();Ar.exports={parse:fn,valid:mn,clean:dn,inc:hn,diff:En,major:gn,minor:In,patch:xn,prerelease:Sn,compare:$n,rcompare:Rn,compareLoose:An,compareBuild:Nn,sort:Ln,rsort:wn,gt:yn,lt:vn,eq:Tn,neq:On,gte:Cn,lte:bn,cmp:Fn,coerce:Dn,Comparator:Pn,Range:qn,satisfies:Vn,toComparators:kn,maxSatisfying:jn,minSatisfying:Gn,minVersion:_n,validRange:Un,outside:Bn,gtr:Mn,ltr:Xn,intersects:Hn,simplifyRange:Wn,subset:Yn,SemVer:pn,re:ye.re,src:ye.src,tokens:ye.t,SEMVER_SPEC_VERSION:$r.SEMVER_SPEC_VERSION,RELEASE_TYPES:$r.RELEASE_TYPES,compareIdentifiers:Rr.compareIdentifiers,rcompareIdentifiers:Rr.rcompareIdentifiers}});var No={};Kr(No,{ngUpdate:()=>Ao});module.exports=Zr(No);var Ur=require("@angular-devkit/schematics/tasks/index.js");var ve=require("@angular-devkit/schematics"),V=Qr(Nr());var Lr=t=>JSON.stringify(t,null,2),ae=(t,e,r)=>{t.exists(e)?t.overwrite(e,r):t.create(e,r)};function Te(t,e){try{return JSON.parse(e.read(t).toString())}catch(r){throw new ve.SchematicsException(`Error when parsing ${t}: ${r.message}`)}}var q="^12.18.0",wr=(t,e)=>{var n;if(!t.exists("package.json"))throw new ve.SchematicsException("Could not locate package.json");let r=Te("package.json",t),s=["dependencies","devDependencies"].filter(o=>{var a;return typeof((a=r[o])==null?void 0:a.firebase)=="string"});if(s.length===0)return(n=r.dependencies)!=null||(r.dependencies={}),r.dependencies.firebase=q,e.logger.info(`Added firebase ${q} to your package.json.`),ae(t,"package.json",Lr(r)),!0;let i=!1;for(let o of s){let a=r[o].firebase,c;try{c=(0,V.subset)(a,q)}catch(l){e.logger.warn(`\u26A0\uFE0F The firebase version in your package.json (${a}) is not a semver range, so it was left as-is; make sure it resolves inside ${q}, the range @angular/fire requires; a version outside it can leave the install with two copies of the firebase SDK.`);continue}c||(r[o].firebase=q,e.logger.info(`Updated the firebase version in your package.json from ${a} to ${q}, the range @angular/fire requires; a workspace range outside it can leave the install with a second copy of the firebase SDK, which fails at runtime.`),i=!0)}return i&&ae(t,"package.json",Lr(r)),i};var kr=require("path");var yr=require("path"),vr=()=>{if(typeof require!="function")return;let t=[()=>require("typescript"),()=>require("module").createRequire((0,yr.join)(process.cwd(),"package.json"))("typescript")];for(let e of t)try{return e()}catch(r){}};var k=(t,e,r)=>{let s=[e];for(;s.length>0;){let i=s.pop();if(!i||r(i)===!1)continue;let n=[];t.forEachChild(i,o=>{n.push(o)});for(let o=n.length-1;o>=0;o--)s.push(n[o])}};var O={"@angular/fire/vertexai":"@angular/fire/ai","@angular/fire/vertexai-preview":"@angular/fire/ai","firebase/vertexai":"firebase/ai","firebase/vertexai-preview":"firebase/ai"},y={provideVertexAI:"provideAI",VertexAI:"AI",VertexAIError:"AIError",VertexAIErrorCode:"AIErrorCode",VertexAIModel:"AIModel",VertexAIInstances:"AIInstances",vertexAIInstance$:"AIInstance$",VertexAIModule:"AIModule"},j={VertexAIOptions:"the new AIOptions takes a backend instead of a location, rebuild the options by hand",getImagenModel:"the Imagen models were shut down in August 2026 and firebase 12.18 removed the API, move image generation to the Gemini image models through getGenerativeModel"},C="getVertexAI",D="getAI",L="AgentPlatformBackend";var Tr=new Set([...Object.keys(O),...Object.values(O)]);var Or=(t,e)=>{let{sourceFile:r}=t,s={edits:[],renamedLocalBindings:new Map,namespaceBindings:new Set,editedSpecifierTokenStarts:new Set,vertexImports:[],vertexExportSpecifiers:[],shadowedImports:[],starExportPositions:[],removedSymbols:[]};for(let i of r.statements)zn(i,t,s,e);return s},zn=(t,e,r,s)=>{var d;let{compiler:i,sourceFile:n}=e,o=i.isImportDeclaration(t),a=i.isExportDeclaration(t);if(!o&&!a)return;let c=t.moduleSpecifier,l=c&&i.isStringLiteral(c)&&O[c.text];if(!l)return;if(a&&(!t.exportClause||i.isNamespaceExport(t.exportClause))){r.starExportPositions.push(t.getStart(n));return}r.edits.push({start:c.getStart(n)+1,end:c.getEnd()-1,replacement:l});let u=o?(d=t.importClause)==null?void 0:d.namedBindings:t.exportClause;if(u&&i.isNamespaceImport(u)){s.has(u.name.text)?r.shadowedImports.push({position:u.getStart(n),name:u.name.text}):r.namespaceBindings.add(u.name.text);return}if(u&&(i.isNamedImports(u)||i.isNamedExports(u)))for(let g of u.elements)Kn(g,t,e,r,s)},Kn=(t,e,r,s,i)=>{var u;let{compiler:n,sourceFile:o}=r,a=(u=t.propertyName)!=null?u:t.name;if(n.isImportSpecifier(t)&&i.has(t.name.text)){s.shadowedImports.push({position:t.getStart(o),name:t.name.text});return}if(a.text===C){n.isImportSpecifier(t)&&n.isImportDeclaration(e)?s.vertexImports.push({element:t,statement:e,localName:t.name.text}):n.isExportSpecifier(t)&&s.vertexExportSpecifiers.push(t);return}if(j[a.text]!==void 0){s.removedSymbols.push({position:a.getStart(o),name:a.text});return}let c=y[a.text];if(!c)return;let l=n.isExportSpecifier(t)&&!t.propertyName;s.edits.push({start:a.getStart(o),end:a.getEnd(),replacement:l?`${c} as ${a.text}`:c}),s.editedSpecifierTokenStarts.add(a.getStart(o)),n.isImportSpecifier(t)&&!t.propertyName&&s.renamedLocalBindings.set(t.name.text,c)},Cr=(t,e,r,s)=>{let{compiler:i,sourceFile:n}=t,o={renamedNames:new Set(e.renamedLocalBindings.keys()),namespaceNames:e.namespaceBindings,vertexNames:new Set(r.keys())};k(i,n,a=>{let c=io(a,e.namespaceBindings,t);c&&e.edits.push(c);let l=Qn(a,e.namespaceBindings,t);if(l&&e.removedSymbols.push(l),Zn(a,e.namespaceBindings,t,s,o),i.isIdentifier(a)){Jn(a,r,t,s,o);let u=no(a,e,t);u&&e.edits.push(u)}})},Qn=(t,e,r)=>{let{compiler:s,sourceFile:i}=r;if(s.isPropertyAccessExpression(t)&&s.isIdentifier(t.expression)&&e.has(t.expression.text)&&j[t.name.text]!==void 0)return{position:t.name.getStart(i),name:t.name.text};if(s.isQualifiedName(t)&&s.isIdentifier(t.left)&&e.has(t.left.text)&&j[t.right.text]!==void 0)return{position:t.right.getStart(i),name:t.right.text}},Zn=(t,e,r,s,i)=>{let{compiler:n,sourceFile:o}=r;if(!n.isPropertyAccessExpression(t)||!n.isIdentifier(t.expression)||!e.has(t.expression.text)||t.name.text!==C)return;let a=t.parent;if(n.isCallExpression(a)&&a.expression===t){br(a,{namespaceAccess:t},r,s,"namespace",i);return}s.unsupported.push({position:t.getStart(o),reason:`a use of ${t.expression.text}.getVertexAI that is not a direct call`,origin:"namespace"})},Jn=(t,e,r,s,i)=>{let{compiler:n,sourceFile:o}=r,a=e.get(t.text);if(!a||Oe(r,t))return;let c=t.parent;if(n.isCallExpression(c)&&c.expression===t){br(c,{binding:a},r,s,"binding",i);return}s.unsupported.push({position:t.getStart(o),reason:n.isExportSpecifier(c)?"a re-export of getVertexAI (rewriting it to getAI would silently change its callers' backend)":"a use of getVertexAI that is not a direct call (only direct calls can be rewritten safely)",origin:"binding"})},eo=(t,e,r)=>{let{compiler:s}=e;if(Oe(e,t))return!1;if(r.renamedNames.has(t.text)||r.vertexNames.has(t.text))return!0;if(!r.namespaceNames.has(t.text))return!1;let i=t.parent;return s.isPropertyAccessExpression(i)&&i.expression===t?y[i.name.text]!==void 0||i.name.text===C:s.isQualifiedName(i)&&i.left===t?y[i.right.text]!==void 0:!1},to=(t,e,r)=>{let{compiler:s}=e,i=!1;return k(s,t,n=>{if(i)return!1;if(s.isIdentifier(n)&&eo(n,e,r))return i=!0,!1}),i},ro=(t,e,r)=>{let{compiler:s,sourceFile:i}=e;if(!s.isObjectLiteralExpression(t))return{supported:!1};if(to(t,e,r))return{supported:!1,conflicting:!0};if(t.properties.length===0)return{supported:!0};let n=t.properties.length===1?t.properties[0]:void 0;return n&&s.isPropertyAssignment(n)&&s.isIdentifier(n.name)&&n.name.text==="location"?{supported:!0,locationText:n.initializer.getText(i),locationFallback:so(n.initializer,e)}:n&&s.isShorthandPropertyAssignment(n)&&n.name.text==="location"?{supported:!0,locationText:"location",locationFallback:"possible"}:{supported:!1}},so=(t,{compiler:e})=>e.isStringLiteral(t)||e.isNoSubstitutionTemplateLiteral(t)?t.text===""?"certain":void 0:e.isIdentifier(t)&&t.text==="undefined"?"certain":"possible",br=(t,e,r,s,i,n)=>{let{compiler:o,sourceFile:a}=r,c=t.arguments,l=c.some(o.isSpreadElement);if(c.length<=1&&!l){s.supportedCalls.push(ce({call:t},e));return}let u=!1;if(c.length===2&&!l){let d=ro(c[1],r,n);if(d.supported){s.supportedCalls.push(De(ce({call:t},e),{locationText:d.locationText,locationFallback:d.locationFallback}));return}u=d.conflicting===!0}s.unsupported.push({position:t.getStart(a),reason:u?"a getVertexAI call whose options mention other symbols this migration rewrites (replacing both at once would conflict)":"a getVertexAI call whose arguments do not map onto getAI safely (only an optional app argument plus an optional literal `{ location }` object are rewritten)",origin:i})},io=(t,e,r)=>{let{compiler:s,sourceFile:i}=r;if(s.isPropertyAccessExpression(t)&&s.isIdentifier(t.expression)&&e.has(t.expression.text)&&y[t.name.text])return{start:t.name.getStart(i),end:t.name.getEnd(),replacement:y[t.name.text]};if(s.isQualifiedName(t)&&s.isIdentifier(t.left)&&e.has(t.left.text)&&y[t.right.text])return{start:t.right.getStart(i),end:t.right.getEnd(),replacement:y[t.right.text]}},no=(t,e,r)=>{let{compiler:s,sourceFile:i}=r,n=e.renamedLocalBindings.get(t.text);if(n===void 0)return;let o=t.getStart(i);if(e.editedSpecifierTokenStarts.has(o)||Oe(r,t))return;let a=t.parent;if(s.isExportSpecifier(a)&&a.name===t&&!a.propertyName){let c=a.parent.parent;return s.isExportDeclaration(c)&&!c.moduleSpecifier?{start:o,end:t.getEnd(),replacement:`${n} as ${t.text}`}:void 0}return s.isShorthandPropertyAssignment(a)&&a.name===t?{start:t.getEnd(),end:t.getEnd(),replacement:`: ${n}`}:{start:o,end:t.getEnd(),replacement:n}},Oe=(t,e)=>{let{compiler:r}=t,s=e.parent;return r.isImportSpecifier(s)&&(s.propertyName===e||s.name===e)||r.isBindingElement(s)&&(s.propertyName===e||s.name===e&&!s.propertyName)?!0:oo(t,e,s)},oo=(t,e,r)=>{let{compiler:s}=t,i=s.isPropertyAccessExpression(r)&&r.name===e||s.isQualifiedName(r)&&r.right===e,n=(s.isPropertyAssignment(r)||s.isPropertyDeclaration(r)||s.isPropertySignature(r)||s.isMethodDeclaration(r)||s.isGetAccessorDeclaration(r)||s.isSetAccessorDeclaration(r)||s.isEnumMember(r))&&r.name===e;return i||n};var ao=t=>{let{compiler:e,sourceFile:r}=t,s=new Set;for(let i of r.statements)(e.isImportDeclaration(i)||e.isExportDeclaration(i))&&i.moduleSpecifier&&e.isStringLiteral(i.moduleSpecifier)&&O[i.moduleSpecifier.text]&&s.add(i);return s},co=(t,e)=>{var i,n;let{compiler:r}=t,s=new Set;for(let o of e){if(!r.isImportDeclaration(o))continue;let a=(i=o.importClause)==null?void 0:i.namedBindings;if(a){if(r.isNamespaceImport(a)){s.add(a.name.text);continue}for(let c of a.elements){let l=((n=c.propertyName)!=null?n:c.name).text;(l===C||y[l]&&!c.propertyName)&&s.add(c.name.text)}}}return s},Fr=(t,e)=>{let{compiler:r}=t;if((r.isVariableDeclaration(e)||r.isParameter(e)||r.isBindingElement(e))&&r.isIdentifier(e.name)||(r.isFunctionDeclaration(e)||r.isFunctionExpression(e)||r.isClassDeclaration(e)||r.isClassExpression(e)||r.isInterfaceDeclaration(e)||r.isTypeAliasDeclaration(e)||r.isEnumDeclaration(e))&&e.name||r.isTypeParameterDeclaration(e)||r.isImportSpecifier(e)||r.isNamespaceImport(e)||r.isImportClause(e)&&e.name)return e.name.text},lo=(t,e)=>{let{compiler:r}=t;if(!r.isImportSpecifier(e)||e.propertyName)return!1;let s=e;for(;s&&!r.isImportDeclaration(s);)s=s.parent;return!s||!r.isImportDeclaration(s)?!1:r.isStringLiteral(s.moduleSpecifier)&&Tr.has(s.moduleSpecifier.text)},Dr=t=>{let{compiler:e,sourceFile:r}=t,s=ao(t),i=co(t,s),n=new Set;return i.size===0||k(e,r,o=>{if(s.has(o))return!1;let a=Fr(t,o);a&&i.has(a)&&n.add(a)}),n},Pr=t=>{let{compiler:e,sourceFile:r}=t,s=[];return k(e,r,i=>{let n=Fr(t,i);(n===D||n===L)&&!lo(t,i)&&s.push({position:i.getStart(r),name:n})}),s};var qr=(t,e,r,s)=>{let{sourceFile:i}=t,n=[],o=[],a=[],c=[],l=[],u=s.length>0&&e.vertexImports.length>0,d=r.unsupported.some(p=>p.origin==="binding")||u,g=new Set;for(let p of r.supportedCalls){if(p.binding&&d){l.push(p.call.getStart(i));continue}let b=p.namespaceAccess?`${p.namespaceAccess.expression.getText(i)}.${L}`:L;if(p.binding&&(g.add(p.binding.statement),p.binding.localName===C)){let T=p.call.expression;n.push({start:T.getStart(i),end:T.getEnd(),replacement:D})}if(p.namespaceAccess){let T=p.namespaceAccess.name;n.push({start:T.getStart(i),end:T.getEnd(),replacement:D})}n.push(...po(p,t,b)),o.push(p.call.getStart(i));let G={position:p.call.getStart(i),backendReference:b};p.locationText===void 0||p.locationFallback==="certain"?a.push(G):p.locationFallback==="possible"&&c.push(G)}if(!d){let p=uo(t),b=p.has(L);for(let G of e.vertexImports){let T=g.has(G.statement)&&!b;n.push(...fo(G,T,p.has(D),t)),T&&(b=!0)}}return{edits:n,callPositions:o,defaultedLocations:a,conditionalLocations:c,blockedCallPositions:l,injectionBlocked:u}},uo=t=>{let{compiler:e,sourceFile:r}=t,s=new Set;for(let i of r.statements){if(!e.isImportDeclaration(i)||!i.importClause)continue;i.importClause.name&&s.add(i.importClause.name.text);let n=i.importClause.namedBindings;if(n)if(e.isNamespaceImport(n))s.add(n.name.text);else for(let o of n.elements)s.add(o.name.text)}return s},po=(t,e,r)=>{var c;let{sourceFile:s}=e,i=t.locationFallback==="certain"?"":(c=t.locationText)!=null?c:"",n=`{ backend: new ${r}(${i}) }`,o=t.call.arguments;if(o.length===0)return[{start:t.call.getEnd()-1,end:t.call.getEnd()-1,replacement:`undefined, ${n}`}];if(o.length===1){let l=o[0];return[{start:l.getEnd(),end:l.getEnd(),replacement:`, ${n}`}]}let a=o[1];return[{start:a.getStart(s),end:a.getEnd(),replacement:n}]},fo=(t,e,r,s)=>{var d,g;let{compiler:i,sourceFile:n}=s,o=[],a=(d=t.statement.importClause)==null?void 0:d.namedBindings;if(!a||!i.isNamedImports(a))return o;let c=a.elements,l=t.element,u=(g=l.propertyName)!=null?g:l.name;if(!l.propertyName&&r){if(e)return[{start:l.getStart(n),end:l.getEnd(),replacement:L}];if(c.length===1)return[{start:l.getStart(n),end:l.getEnd(),replacement:""}];let p=c.indexOf(l);return p>0?[{start:c[p-1].getEnd(),end:l.getEnd(),replacement:""}]:[{start:l.getStart(n),end:c[1].getStart(n),replacement:""}]}return o.push({start:u.getStart(n),end:u.getEnd(),replacement:D}),e&&o.push({start:l.getEnd(),end:l.getEnd(),replacement:`, ${L}`}),o};var v="see the AngularFire v21 upgrade guide (docs/version-21-upgrade.md)",mo=["getLiveGenerativeModel","startAudioConversation"],jr="This workspace calls the Live API, which Firebase does not support in the global location, so leaving this on global stops getLiveGenerativeModel and startAudioConversation from working. ",ho=(t,e)=>e?`Pass a location that supports the Live API to ${t}, ${v}`:`Pass new ${t}('us-central1') to keep the region you had, ${v}`,Eo=t=>{let{sourceFile:e}=t,r=Or(t,Dr(t)),s=new Map;for(let a of r.vertexImports)s.set(a.localName,a);let i={supportedCalls:[],unsupported:[]};(r.renamedLocalBindings.size>0||r.namespaceBindings.size>0||s.size>0)&&Cr(t,r,s,i);for(let a of r.vertexExportSpecifiers)i.unsupported.push({position:a.getStart(e),reason:"a re-export of getVertexAI (rewriting it to getAI would silently change its callers' backend)",origin:"export"});let n=r.vertexImports.length>0?Pr(t):[],o=qr(t,r,i,n);return{edits:r.edits.concat(o.edits),vertexCallPositions:o.callPositions,defaultedLocations:o.defaultedLocations,conditionalLocations:o.conditionalLocations,blockedCallPositions:o.blockedCallPositions,unsupportedVertexUsages:i.unsupported,shadowedImports:r.shadowedImports,injectionConflicts:o.injectionBlocked?n:[],starExportPositions:r.starExportPositions,removedSymbols:r.removedSymbols}},Gr=(t,e,r)=>t.length===0?`this call ${e}`:`this call and ${t.length} other${t.length===1?"":"s"} in this file ${r}`,go=(t,e)=>{let[r,...s]=t.defaultedLocations;return r===void 0?[]:[{level:"warn",position:r.position,text:`${Gr(s,"now passes","now pass")} no location, so the region changed from us-central1 to global. us-central1 was getVertexAI's default and global is ${L}'s. `+(e?jr:"")+ho(r.backendReference,e)}]},Io=(t,e)=>{let[r,...s]=t.conditionalLocations;return r===void 0?[]:[{level:"warn",position:r.position,text:`${Gr(s,"passes","pass")} a location this migration cannot resolve. An empty value used to mean us-central1 and now means global, so the region changes if that expression is ever empty. `+(e?jr:"")+`Check it, ${v}`}]},xo=(t,e)=>[...t.vertexCallPositions.map(r=>({level:"info",position:r,text:`rewrote getVertexAI(...) to getAI(..., { backend: new ${L}(...) }) to keep the call on the Agent Platform Gemini API (formerly Vertex AI)`})),...go(t,e),...Io(t,e),...t.unsupportedVertexUsages.map(r=>({level:"warn",position:r.position,text:`left ${r.reason}. Plain getAI() uses the Gemini Developer API backend, NOT Vertex AI. Migrate this site by hand, ${v}`})),...t.shadowedImports.map(r=>({level:"warn",position:r.position,text:`left the \`${r.name}\` import name and its usages unrenamed: this file also declares a local named \`${r.name}\`, and name-based rewriting cannot tell the two apart. The import path itself still moves to the new entry point, so the leftover name fails to compile there. Migrate this file by hand, ${v}`})),...t.injectionConflicts.map(r=>({level:"warn",position:r.position,text:`\`${r.name}\` is already bound here from a source other than AI Logic, so the backend-preserving rewrite cannot inject or reuse it. The file's getVertexAI code was left as is, and its import path still moves to the new entry point, so the leftover getVertexAI fails to compile there. Migrate it by hand, ${v}`})),...t.blockedCallPositions.map(r=>({level:"warn",position:r,text:t.injectionConflicts.length>0?`left a rewritable getVertexAI call unrewritten because this file binds getAI or ${L} from another source (see that warning). Every use of the file's named getVertexAI imports is kept together so the pieces stay consistent, migrate them by hand`:"left a rewritable getVertexAI call unrewritten because another getVertexAI use in this file cannot be rewritten (see its own warning). Every use of the file's named getVertexAI imports is kept together so the pieces stay consistent, migrate them by hand"})),...t.starExportPositions.map(r=>({level:"warn",position:r,text:`left \`export *\` from an old Vertex AI entry point unmigrated: rewriting it would silently rename this file's re-exported public symbols. Re-export what you need by name from '@angular/fire/ai' instead, ${v}`})),...t.removedSymbols.map(r=>({level:"warn",position:r.position,text:`left \`${r.name}\`, which no longer exists in the new entry point (${j[r.name]}). The leftover name fails to compile, migrate it by hand, ${v}`}))],So=(t,e,r,s,i,n)=>{let o={compiler:r,sourceFile:r.createSourceFile(s,i,r.ScriptTarget.Latest,!0)},a=o.sourceFile;if(a.parseDiagnostics&&a.parseDiagnostics.length>0)return e.logger.warn(`${s}: skipped, the file has syntax errors, so the Vertex AI -> AI Logic rewrite cannot run on it safely. Fix the syntax and re-run ng update, or migrate it by hand, ${v}`),!1;let c=Eo(o);for(let u of xo(c,n)){let d=o.sourceFile.getLineAndCharacterOfPosition(u.position).line+1;e.logger[u.level](`${s}:${d}: ${u.text}`)}if(c.edits.length===0)return!1;let l;try{l=$o(i,c.edits)}catch(u){return e.logger.warn(`${s}: the Vertex AI -> AI Logic rewrite was skipped for this file (${u}). Migrate it by hand, ${v}`),!1}return l===i?!1:(ae(t,s,l),!0)},$o=(t,e)=>{let r=e.slice().sort((s,i)=>i.start-s.start||i.end-s.end);for(let s=1;s<r.length;s++)if(r[s].end>r[s-1].start)throw new Error(`conflicting rewrite edits at offsets ${r[s].start} and ${r[s-1].start}`);return r.reduce((s,i)=>s.slice(0,i.start)+i.replacement+s.slice(i.end),t)},Ro=t=>Object.values(t.projects).map(e=>(e==null?void 0:e.sourceRoot)||(e==null?void 0:e.root)).filter(e=>typeof e=="string").map(e=>{let r=kr.posix.join("/",e);return r==="/"?r:r.replace(/\/+$/,"")}),Vr=(t,e)=>t.endsWith(".ts")&&!t.endsWith(".d.ts")&&!t.split("/").includes("node_modules")&&e.some(r=>r==="/"||t===r||t.startsWith(r+"/")),_r=(t,e,r)=>{let s=r!=null?r:vr(),i=t.exists("angular.json")&&Te("angular.json",t);if(!(i!=null&&i.projects))return!1;let n=Ro(i);if(n.length===0)return!1;let o=!1;t.visit(c=>{var u;if(o||!Vr(c,n))return;let l=(u=t.read(c))==null?void 0:u.toString();o||(o=l!==void 0&&mo.some(d=>l.includes(d)))});let a=!1;return t.visit(c=>{var u;if(!Vr(c,n))return;let l=(u=t.read(c))==null?void 0:u.toString();if(!(!l||!Object.keys(O).some(d=>l.includes(d)))){if(!s){e.logger.warn(`${c} imports a removed Vertex AI entry point, but the Vertex AI -> AI Logic rewrite was skipped: the \`typescript\` package could not be resolved (it is an optional peer dependency of @angular/fire). Install typescript and re-run, or migrate by hand - see the v21 upgrade guide (docs/version-21-upgrade.md).`);return}a=So(t,e,s,c,l,o)||a}}),a};var Ao=t=>(e,r)=>{wr(e,r)&&r.addTask(new Ur.NodePackageInstallTask);try{_r(e,r,t==null?void 0:t.compiler)}catch(s){r.logger.warn(`Skipped the Vertex AI -> AI Logic source rewrite: ${s}. Any remaining @angular/fire/vertexai imports need a manual migration - see the v21 upgrade guide (docs/version-21-upgrade.md).`)}return e};0&&(module.exports={ngUpdate});
|