@sddsjs/design-system-builder-cli 0.0.0-stage → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (63) hide show
  1. package/LICENSE +4 -0
  2. package/README.md +969 -2
  3. package/bin/dsbuilder.js +2 -0
  4. package/dist/kotlin/Kotlin-Immutable-Collections-kotlinx-collections-immutable.js +3170 -0
  5. package/dist/kotlin/Stately-stately-concurrency.js +32 -0
  6. package/dist/kotlin/Stately-stately-concurrent-collections.js +302 -0
  7. package/dist/kotlin/Stately-stately-strict.js +12 -0
  8. package/dist/kotlin/clikt-clikt-mordant.js +304 -0
  9. package/dist/kotlin/clikt-clikt.js +6960 -0
  10. package/dist/kotlin/colormath-root-colormath.js +1653 -0
  11. package/dist/kotlin/design-system-builder-frontend-analytics-metrica.js +1026 -0
  12. package/dist/kotlin/design-system-builder-frontend-cli.js +10690 -0
  13. package/dist/kotlin/design-system-builder-frontend-core-analytics.js +128 -0
  14. package/dist/kotlin/design-system-builder-frontend-core-application.js +3634 -0
  15. package/dist/kotlin/design-system-builder-frontend-core-auth.js +1772 -0
  16. package/dist/kotlin/design-system-builder-frontend-core-domain.js +501 -0
  17. package/dist/kotlin/design-system-builder-frontend-core-network.js +3318 -0
  18. package/dist/kotlin/design-system-builder-frontend-core-platform.js +972 -0
  19. package/dist/kotlin/design-system-builder-frontend-core-process.js +236 -0
  20. package/dist/kotlin/design-system-builder-frontend-core-workspace.js +1058 -0
  21. package/dist/kotlin/design-system-builder-frontend-feature-auth.js +1664 -0
  22. package/dist/kotlin/design-system-builder-frontend-feature-components.js +24819 -0
  23. package/dist/kotlin/design-system-builder-frontend-feature-docs.js +7625 -0
  24. package/dist/kotlin/design-system-builder-frontend-feature-ds.js +2219 -0
  25. package/dist/kotlin/design-system-builder-frontend-feature-init.js +318 -0
  26. package/dist/kotlin/design-system-builder-frontend-feature-projects.js +624 -0
  27. package/dist/kotlin/design-system-builder-frontend-feature-status.js +984 -0
  28. package/dist/kotlin/design-system-builder-frontend-feature-theme.js +10456 -0
  29. package/dist/kotlin/design-system-builder-frontend-feature-toolchain.js +586 -0
  30. package/dist/kotlin/design-system-builder-frontend-mcp-server-core.js +6878 -0
  31. package/dist/kotlin/design-system-builder-frontend-platform-android.js +451 -0
  32. package/dist/kotlin/design-system-builder-frontend-platform-ios.js +1858 -0
  33. package/dist/kotlin/design-system-builder-frontend-platform-web.js +1555 -0
  34. package/dist/kotlin/design-system-builder-frontend-runtime-node.js +1763 -0
  35. package/dist/kotlin/kotlin-kotlin-stdlib.js +17881 -0
  36. package/dist/kotlin/kotlin-logging.js +440 -0
  37. package/dist/kotlin/kotlin-sdk-kotlin-sdk-core.js +20228 -0
  38. package/dist/kotlin/kotlin-sdk-kotlin-sdk-server.js +2771 -0
  39. package/dist/kotlin/kotlin_org_jetbrains_kotlin_kotlin_dom_api_compat.js +8 -0
  40. package/dist/kotlin/kotlinx-atomicfu.js +252 -0
  41. package/dist/kotlin/kotlinx-coroutines-core.js +10822 -0
  42. package/dist/kotlin/kotlinx-io-kotlinx-io-bytestring.js +203 -0
  43. package/dist/kotlin/kotlinx-io-kotlinx-io-core.js +2032 -0
  44. package/dist/kotlin/kotlinx-serialization-kotlinx-serialization-core.js +6171 -0
  45. package/dist/kotlin/kotlinx-serialization-kotlinx-serialization-json.js +5690 -0
  46. package/dist/kotlin/ktor-ktor-client-core.js +8382 -0
  47. package/dist/kotlin/ktor-ktor-events.js +80 -0
  48. package/dist/kotlin/ktor-ktor-http-cio.js +2252 -0
  49. package/dist/kotlin/ktor-ktor-http.js +3320 -0
  50. package/dist/kotlin/ktor-ktor-io.js +3328 -0
  51. package/dist/kotlin/ktor-ktor-serialization.js +8 -0
  52. package/dist/kotlin/ktor-ktor-server-core.js +12 -0
  53. package/dist/kotlin/ktor-ktor-server-sse.js +8 -0
  54. package/dist/kotlin/ktor-ktor-server-websockets.js +8 -0
  55. package/dist/kotlin/ktor-ktor-sse.js +8 -0
  56. package/dist/kotlin/ktor-ktor-utils.js +2524 -0
  57. package/dist/kotlin/ktor-ktor-websocket-serialization.js +8 -0
  58. package/dist/kotlin/ktor-ktor-websockets.js +433 -0
  59. package/dist/kotlin/mordant-mordant-omnibus.js +8 -0
  60. package/dist/kotlin/mordant-mordant.js +12111 -0
  61. package/dist/kotlin/okio-parent-okio.js +2335 -0
  62. package/dist/kotlin/projects-core-koin-core.js +1285 -0
  63. package/package.json +26 -5
@@ -0,0 +1,3634 @@
1
+ (function (_, kotlin_kotlin, kotlin_design_system_builder_frontend_core_auth, kotlin_design_system_builder_frontend_core_process, kotlin_design_system_builder_frontend_core_domain, kotlin_design_system_builder_frontend_core_workspace, kotlin_io_insert_koin_koin_core, kotlin_design_system_builder_frontend_core_network) {
2
+ 'use strict';
3
+ //region block: imports
4
+ var imul = Math.imul;
5
+ var Unit_instance = kotlin_kotlin.$_$.r5;
6
+ var VOID = kotlin_kotlin.$_$.c;
7
+ var UserAccessTokenCache = kotlin_design_system_builder_frontend_core_auth.$_$.t;
8
+ var UnavailablePkcePlatform_instance = kotlin_design_system_builder_frontend_core_auth.$_$.g1;
9
+ var protoOf = kotlin_kotlin.$_$.te;
10
+ var toString = kotlin_kotlin.$_$.we;
11
+ var toString_0 = kotlin_kotlin.$_$.bm;
12
+ var hashCode = kotlin_kotlin.$_$.pd;
13
+ var getBooleanHashCode = kotlin_kotlin.$_$.ld;
14
+ var equals = kotlin_kotlin.$_$.jd;
15
+ var initMetadataForClass = kotlin_kotlin.$_$.qd;
16
+ var ProcessLaunchException = kotlin_design_system_builder_frontend_core_process.$_$.a;
17
+ var ProcessRunner = kotlin_design_system_builder_frontend_core_process.$_$.d;
18
+ var initMetadataForObject = kotlin_kotlin.$_$.wd;
19
+ var CredentialStore = kotlin_design_system_builder_frontend_core_auth.$_$.h;
20
+ var AuthErrorCode_AUTH_REQUIRED_getInstance = kotlin_design_system_builder_frontend_core_auth.$_$.w;
21
+ var Failed = kotlin_design_system_builder_frontend_core_auth.$_$.b;
22
+ var username = kotlin_design_system_builder_frontend_core_auth.$_$.f1;
23
+ var clientCredentials = kotlin_design_system_builder_frontend_core_auth.$_$.e1;
24
+ var TokenClient = kotlin_design_system_builder_frontend_core_auth.$_$.r;
25
+ var isBlank = kotlin_kotlin.$_$.gh;
26
+ var _ProjectId___get_value__impl__lfubnr = kotlin_design_system_builder_frontend_core_domain.$_$.g1;
27
+ var _ProjectId___init__impl__b1fobp = kotlin_design_system_builder_frontend_core_domain.$_$.d1;
28
+ var _DesignSystemId___get_value__impl__wgtkjx = kotlin_design_system_builder_frontend_core_domain.$_$.y;
29
+ var _DesignSystemId___init__impl__6op7ax = kotlin_design_system_builder_frontend_core_domain.$_$.v;
30
+ var _CredentialEnvName___init__impl__w41seg = kotlin_design_system_builder_frontend_core_domain.$_$.r;
31
+ var listOfNotNull = kotlin_kotlin.$_$.c9;
32
+ var CredentialPolicy_AUTO_getInstance = kotlin_design_system_builder_frontend_core_domain.$_$.j;
33
+ var ContextProvenance_EXPLICIT_LINK_getInstance = kotlin_design_system_builder_frontend_core_domain.$_$.i;
34
+ var ProjectContext = kotlin_design_system_builder_frontend_core_domain.$_$.f;
35
+ var noWhenBranchMatchedException = kotlin_kotlin.$_$.vl;
36
+ var initMetadataForInterface = kotlin_kotlin.$_$.ud;
37
+ var ProjectConfigException = kotlin_design_system_builder_frontend_core_workspace.$_$.b;
38
+ var ProjectNotInitializedException = kotlin_design_system_builder_frontend_core_workspace.$_$.h;
39
+ var getStringHashCode = kotlin_kotlin.$_$.od;
40
+ var module_0 = kotlin_io_insert_koin_koin_core.$_$.g;
41
+ var getKClass = kotlin_kotlin.$_$.qf;
42
+ var WorkspaceFileSystem = kotlin_design_system_builder_frontend_core_workspace.$_$.i;
43
+ var ProjectConfigStore = kotlin_design_system_builder_frontend_core_workspace.$_$.c;
44
+ var EnvironmentReader = kotlin_design_system_builder_frontend_core_auth.$_$.i;
45
+ var PatResolver = kotlin_design_system_builder_frontend_core_auth.$_$.m;
46
+ var ApiUrlResolver = kotlin_design_system_builder_frontend_core_network.$_$.a;
47
+ var Companion_getInstance = kotlin_io_insert_koin_koin_core.$_$.b;
48
+ var Kind_Singleton_getInstance = kotlin_io_insert_koin_koin_core.$_$.a;
49
+ var emptyList = kotlin_kotlin.$_$.y7;
50
+ var BeanDefinition = kotlin_io_insert_koin_koin_core.$_$.c;
51
+ var SingleInstanceFactory = kotlin_io_insert_koin_koin_core.$_$.e;
52
+ var KoinDefinition = kotlin_io_insert_koin_koin_core.$_$.d;
53
+ var PkcePlatform = kotlin_design_system_builder_frontend_core_auth.$_$.o;
54
+ var AuthenticatedHttpClientFactory = kotlin_design_system_builder_frontend_core_network.$_$.b;
55
+ var Regex_init_$Create$ = kotlin_kotlin.$_$.e1;
56
+ var startsWith = kotlin_kotlin.$_$.gi;
57
+ var _Char___init__impl__6a9atx = kotlin_kotlin.$_$.w2;
58
+ var contains = kotlin_kotlin.$_$.sg;
59
+ var removePrefix = kotlin_kotlin.$_$.wh;
60
+ var charArrayOf = kotlin_kotlin.$_$.bd;
61
+ var split = kotlin_kotlin.$_$.ei;
62
+ var collectionSizeOrDefault = kotlin_kotlin.$_$.y6;
63
+ var ArrayList_init_$Create$ = kotlin_kotlin.$_$.l;
64
+ var to = kotlin_kotlin.$_$.cm;
65
+ var sorted = kotlin_kotlin.$_$.da;
66
+ var listOf = kotlin_kotlin.$_$.e9;
67
+ var listOf_0 = kotlin_kotlin.$_$.f9;
68
+ var toMap = kotlin_kotlin.$_$.pa;
69
+ var Companion_getInstance_0 = kotlin_design_system_builder_frontend_core_domain.$_$.j1;
70
+ var DesignSystemSelection = kotlin_design_system_builder_frontend_core_domain.$_$.a;
71
+ var IllegalArgumentException_init_$Create$ = kotlin_kotlin.$_$.v1;
72
+ var CoroutineImpl = kotlin_kotlin.$_$.tb;
73
+ var get_COROUTINE_SUSPENDED = kotlin_kotlin.$_$.db;
74
+ var initMetadataForCoroutine = kotlin_kotlin.$_$.sd;
75
+ var Long = kotlin_kotlin.$_$.qk;
76
+ var compare = kotlin_kotlin.$_$.fc;
77
+ var CredentialPolicy_USER_SESSION_getInstance = kotlin_design_system_builder_frontend_core_domain.$_$.m;
78
+ var CredentialPolicy_PAT_ENV_getInstance = kotlin_design_system_builder_frontend_core_domain.$_$.k;
79
+ var IllegalArgumentException = kotlin_kotlin.$_$.nk;
80
+ var joinToString = kotlin_kotlin.$_$.r8;
81
+ var IllegalArgumentException_init_$Init$ = kotlin_kotlin.$_$.u1;
82
+ var captureStack = kotlin_kotlin.$_$.ad;
83
+ var Exception = kotlin_kotlin.$_$.mk;
84
+ var decodeToString = kotlin_kotlin.$_$.ug;
85
+ var FunctionAdapter = kotlin_kotlin.$_$.wc;
86
+ var isInterface = kotlin_kotlin.$_$.fe;
87
+ var ProjectEnvParser = kotlin_design_system_builder_frontend_core_workspace.$_$.g;
88
+ var ProjectEnvParseException = kotlin_design_system_builder_frontend_core_workspace.$_$.f;
89
+ var ProjectApiUrl__toString_impl_gcmdir = kotlin_design_system_builder_frontend_core_domain.$_$.b1;
90
+ var CredentialEnvName__toString_impl_prwlz4 = kotlin_design_system_builder_frontend_core_domain.$_$.t;
91
+ var ProjectApiUrl__hashCode_impl_5ejja4 = kotlin_design_system_builder_frontend_core_domain.$_$.a1;
92
+ var CredentialEnvName__hashCode_impl_40qp69 = kotlin_design_system_builder_frontend_core_domain.$_$.s;
93
+ var Enum = kotlin_kotlin.$_$.kk;
94
+ var THROW_CCE = kotlin_kotlin.$_$.wk;
95
+ var AuthenticatedHttpClient = kotlin_design_system_builder_frontend_core_network.$_$.c;
96
+ var initMetadataForLambda = kotlin_kotlin.$_$.vd;
97
+ var Response = kotlin_design_system_builder_frontend_core_network.$_$.i;
98
+ var Bearer = kotlin_design_system_builder_frontend_core_auth.$_$.d;
99
+ var Success = kotlin_design_system_builder_frontend_core_auth.$_$.c;
100
+ var emptyMap = kotlin_kotlin.$_$.z7;
101
+ var AuthenticatedHttpResponse = kotlin_design_system_builder_frontend_core_network.$_$.d;
102
+ var Failure = kotlin_design_system_builder_frontend_core_network.$_$.e;
103
+ var _ProjectApiUrl___init__impl__tmjeh7 = kotlin_design_system_builder_frontend_core_domain.$_$.z;
104
+ var PersonalAccessToken = kotlin_design_system_builder_frontend_core_auth.$_$.e;
105
+ var _CredentialEnvName___get_value__impl__breyj8 = kotlin_design_system_builder_frontend_core_domain.$_$.u;
106
+ var MissingPatException = kotlin_design_system_builder_frontend_core_auth.$_$.k;
107
+ var _ProjectApiUrl___get_value__impl__ub99up = kotlin_design_system_builder_frontend_core_domain.$_$.c1;
108
+ var BackendCredentialType_USER_SESSION_getInstance = kotlin_design_system_builder_frontend_core_auth.$_$.d1;
109
+ var UserSession = kotlin_design_system_builder_frontend_core_auth.$_$.u;
110
+ var BackendCredentialType_PERSONAL_ACCESS_TOKEN_getInstance = kotlin_design_system_builder_frontend_core_auth.$_$.b1;
111
+ var ServiceToken = kotlin_design_system_builder_frontend_core_auth.$_$.f;
112
+ var BackendCredentialType_SERVICE_ACCOUNT_getInstance = kotlin_design_system_builder_frontend_core_auth.$_$.c1;
113
+ var RotatingCredentialStore = kotlin_design_system_builder_frontend_core_auth.$_$.q;
114
+ var System_instance = kotlin_kotlin.$_$.f5;
115
+ var objectCreate = kotlin_kotlin.$_$.se;
116
+ //endregion
117
+ //region block: pre-declaration
118
+ initMetadataForClass(ClientRuntime, 'ClientRuntime');
119
+ initMetadataForObject(UnavailableProcessRunner, 'UnavailableProcessRunner', VOID, VOID, [ProcessRunner], [1]);
120
+ initMetadataForObject(EmptyCredentialStore, 'EmptyCredentialStore', VOID, VOID, [CredentialStore], [1]);
121
+ initMetadataForObject(UnavailableTokenClient, 'UnavailableTokenClient', VOID, VOID, [TokenClient], [4, 2, 3]);
122
+ initMetadataForClass(ContextResolver, 'ContextResolver');
123
+ initMetadataForInterface(ContextSource, 'ContextSource');
124
+ initMetadataForClass(NearestProjectConfigContextSource, 'NearestProjectConfigContextSource', VOID, VOID, [ContextSource]);
125
+ initMetadataForClass(Found, 'Found');
126
+ initMetadataForObject(NotFound, 'NotFound');
127
+ initMetadataForClass(Failed_0, 'Failed');
128
+ initMetadataForObject(DesignSystemLink, 'DesignSystemLink');
129
+ initMetadataForClass(DraftEditOptions, 'DraftEditOptions');
130
+ initMetadataForClass(Executed, 'Executed');
131
+ initMetadataForClass(Failed_1, 'Failed');
132
+ initMetadataForCoroutine($executeCOROUTINE$, CoroutineImpl);
133
+ initMetadataForClass(DraftOperationRunner, 'DraftOperationRunner', VOID, VOID, VOID, [3, 4]);
134
+ function requireContext(request) {
135
+ var tmp;
136
+ if (request.l5q_1 == null) {
137
+ tmp = this.j5s(request.k5q_1);
138
+ } else {
139
+ tmp = new Failed_2('Explicit design-system selection is not supported by this context reader.', ProjectContextFailure_INVALID_CONTEXT_getInstance());
140
+ }
141
+ return tmp;
142
+ }
143
+ function requireContext_0(startingDirectory, designSystemUri) {
144
+ return this.k5s(new ContextRequest(startingDirectory, designSystemUri));
145
+ }
146
+ initMetadataForInterface(ProjectContextReader, 'ProjectContextReader');
147
+ initMetadataForClass(LocalProjectContextReader, 'LocalProjectContextReader', VOID, VOID, [ProjectContextReader]);
148
+ initMetadataForClass(UnknownTargetPlatformException, 'UnknownTargetPlatformException', VOID, IllegalArgumentException);
149
+ initMetadataForClass(sam$com_dsbuilder_frontend_core_auth_EnvironmentReader$0, 'sam$com_dsbuilder_frontend_core_auth_EnvironmentReader$0', VOID, VOID, [EnvironmentReader, FunctionAdapter]);
150
+ initMetadataForClass(ProjectEnvironmentLoader, 'ProjectEnvironmentLoader');
151
+ initMetadataForClass(ProjectEnvironmentException, 'ProjectEnvironmentException', VOID, IllegalArgumentException);
152
+ initMetadataForClass(RuntimeRequest, 'RuntimeRequest', RuntimeRequest);
153
+ initMetadataForClass(Local, 'Local', Local);
154
+ initMetadataForClass(Link, 'Link');
155
+ initMetadataForCoroutine($resolveCOROUTINE$, CoroutineImpl);
156
+ function resolve(request, $completion) {
157
+ return this.p5t(request.i5t_1, request.j5t_1, request.k5t_1, request.l5t_1, $completion);
158
+ }
159
+ function resolve_0(apiUrl, projectKeyOverride, credentialEnvName, policy, $completion) {
160
+ var tmp = new $resolveCOROUTINE$(this, apiUrl, projectKeyOverride, credentialEnvName, policy, $completion);
161
+ tmp.y8_1 = Unit_instance;
162
+ tmp.z8_1 = null;
163
+ return tmp.e9();
164
+ }
165
+ initMetadataForInterface(CredentialProvider, 'CredentialProvider', VOID, VOID, VOID, [1, 3, 4]);
166
+ function resolve_1(override, projectEnvironment) {
167
+ return this.q5t(override);
168
+ }
169
+ initMetadataForInterface(ProjectApiUrlProvider, 'ProjectApiUrlProvider');
170
+ initMetadataForClass(Found_0, 'Found');
171
+ initMetadataForClass(Failed_2, 'Failed');
172
+ initMetadataForClass(Selected, 'Selected');
173
+ initMetadataForClass(Failed_3, 'Failed');
174
+ initMetadataForClass(CredentialRequest, 'CredentialRequest');
175
+ initMetadataForClass(ProjectContextFailure, 'ProjectContextFailure', VOID, Enum);
176
+ initMetadataForInterface(PersonalAccessTokenProvider, 'PersonalAccessTokenProvider');
177
+ initMetadataForClass(ContextRequest, 'ContextRequest', ContextRequest);
178
+ initMetadataForLambda(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$get$slambda, CoroutineImpl, VOID, [1]);
179
+ initMetadataForLambda(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$post$slambda, CoroutineImpl, VOID, [1]);
180
+ initMetadataForLambda(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postJson$slambda, CoroutineImpl, VOID, [1]);
181
+ initMetadataForLambda(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postMultipart$slambda, CoroutineImpl, VOID, [1]);
182
+ initMetadataForLambda(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postMultipart$slambda_1, CoroutineImpl, VOID, [1]);
183
+ initMetadataForLambda(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$clearSession$slambda, CoroutineImpl, VOID, [0]);
184
+ initMetadataForCoroutine($getCOROUTINE$, CoroutineImpl);
185
+ initMetadataForCoroutine($postCOROUTINE$, CoroutineImpl);
186
+ initMetadataForCoroutine($mutateCOROUTINE$, CoroutineImpl);
187
+ initMetadataForCoroutine($retryMultipartCOROUTINE$, CoroutineImpl);
188
+ initMetadataForCoroutine($retryResultCOROUTINE$, CoroutineImpl);
189
+ initMetadataForCoroutine($refreshedClientCOROUTINE$, CoroutineImpl);
190
+ initMetadataForClass(RefreshingClient, 'RefreshingClient', VOID, VOID, [AuthenticatedHttpClient], [1, 2, 0]);
191
+ initMetadataForClass(RefreshingAuthenticatedHttpClientFactory, 'RefreshingAuthenticatedHttpClientFactory', VOID, VOID, [AuthenticatedHttpClientFactory]);
192
+ initMetadataForClass(sam$com_dsbuilder_frontend_core_auth_EnvironmentReader$0_0, 'sam$com_dsbuilder_frontend_core_auth_EnvironmentReader$0', VOID, VOID, [EnvironmentReader, FunctionAdapter]);
193
+ initMetadataForLambda(RuntimeCredentialProvider$resolveSessionCredential$slambda, CoroutineImpl, VOID, [0]);
194
+ initMetadataForLambda(RuntimeCredentialProvider$refreshSession$slambda, CoroutineImpl, VOID, [1]);
195
+ initMetadataForCoroutine($resolveCOROUTINE$_0, CoroutineImpl);
196
+ initMetadataForCoroutine($resolveProjectKeyOrSessionCOROUTINE$, CoroutineImpl);
197
+ initMetadataForCoroutine($resolveServiceOrSessionCOROUTINE$, CoroutineImpl);
198
+ initMetadataForCoroutine($refreshSessionCOROUTINE$, CoroutineImpl);
199
+ initMetadataForCoroutine($toCredentialResultCOROUTINE$, CoroutineImpl);
200
+ initMetadataForClass(RuntimeCredentialProvider, 'RuntimeCredentialProvider', VOID, VOID, [CredentialProvider], [3, 4, 1, 2]);
201
+ initMetadataForClass(RuntimePersonalAccessTokenProvider, 'RuntimePersonalAccessTokenProvider', VOID, VOID, [PersonalAccessTokenProvider]);
202
+ initMetadataForClass(RuntimeProjectApiUrlProvider, 'RuntimeProjectApiUrlProvider', VOID, VOID, [ProjectApiUrlProvider]);
203
+ initMetadataForCoroutine($resolveCOROUTINE$_1, CoroutineImpl);
204
+ initMetadataForClass(RuntimeRequestResolver, 'RuntimeRequestResolver', VOID, VOID, VOID, [1]);
205
+ initMetadataForClass(Resolved, 'Resolved');
206
+ initMetadataForClass(Failed_4, 'Failed');
207
+ initMetadataForClass(RuntimeFailureCode, 'RuntimeFailureCode', VOID, Enum);
208
+ initMetadataForLambda(UserSessionAccess$_init_$slambda_ukeg7x, CoroutineImpl, VOID, [2]);
209
+ initMetadataForClass(UserSessionAccess, 'UserSessionAccess', VOID, VOID, VOID, [2]);
210
+ //endregion
211
+ function ClientRuntime$_init_$lambda_lpjb9a() {
212
+ return Unit_instance;
213
+ }
214
+ function ClientRuntime(fileSystem, environmentReader, httpClientFactory, processRunner, credentialStore, tokenClient, close, accessTokenCache, pkcePlatform, analyticsConsent, supportsIosToolchain) {
215
+ processRunner = processRunner === VOID ? UnavailableProcessRunner_instance : processRunner;
216
+ credentialStore = credentialStore === VOID ? EmptyCredentialStore_instance : credentialStore;
217
+ tokenClient = tokenClient === VOID ? UnavailableTokenClient_instance : tokenClient;
218
+ var tmp;
219
+ if (close === VOID) {
220
+ tmp = ClientRuntime$_init_$lambda_lpjb9a;
221
+ } else {
222
+ tmp = close;
223
+ }
224
+ close = tmp;
225
+ accessTokenCache = accessTokenCache === VOID ? new UserAccessTokenCache() : accessTokenCache;
226
+ pkcePlatform = pkcePlatform === VOID ? UnavailablePkcePlatform_instance : pkcePlatform;
227
+ analyticsConsent = analyticsConsent === VOID ? null : analyticsConsent;
228
+ supportsIosToolchain = supportsIosToolchain === VOID ? true : supportsIosToolchain;
229
+ this.p5p_1 = fileSystem;
230
+ this.q5p_1 = environmentReader;
231
+ this.r5p_1 = httpClientFactory;
232
+ this.s5p_1 = processRunner;
233
+ this.t5p_1 = credentialStore;
234
+ this.u5p_1 = tokenClient;
235
+ this.v5p_1 = close;
236
+ this.w5p_1 = accessTokenCache;
237
+ this.x5p_1 = pkcePlatform;
238
+ this.y5p_1 = analyticsConsent;
239
+ this.z5p_1 = supportsIosToolchain;
240
+ }
241
+ protoOf(ClientRuntime).a5q = function (fileSystem, environmentReader, httpClientFactory, processRunner, credentialStore, tokenClient, close, accessTokenCache, pkcePlatform, analyticsConsent, supportsIosToolchain) {
242
+ return new ClientRuntime(fileSystem, environmentReader, httpClientFactory, processRunner, credentialStore, tokenClient, close, accessTokenCache, pkcePlatform, analyticsConsent, supportsIosToolchain);
243
+ };
244
+ protoOf(ClientRuntime).b5q = function (fileSystem, environmentReader, httpClientFactory, processRunner, credentialStore, tokenClient, close, accessTokenCache, pkcePlatform, analyticsConsent, supportsIosToolchain, $super) {
245
+ fileSystem = fileSystem === VOID ? this.p5p_1 : fileSystem;
246
+ environmentReader = environmentReader === VOID ? this.q5p_1 : environmentReader;
247
+ httpClientFactory = httpClientFactory === VOID ? this.r5p_1 : httpClientFactory;
248
+ processRunner = processRunner === VOID ? this.s5p_1 : processRunner;
249
+ credentialStore = credentialStore === VOID ? this.t5p_1 : credentialStore;
250
+ tokenClient = tokenClient === VOID ? this.u5p_1 : tokenClient;
251
+ close = close === VOID ? this.v5p_1 : close;
252
+ accessTokenCache = accessTokenCache === VOID ? this.w5p_1 : accessTokenCache;
253
+ pkcePlatform = pkcePlatform === VOID ? this.x5p_1 : pkcePlatform;
254
+ analyticsConsent = analyticsConsent === VOID ? this.y5p_1 : analyticsConsent;
255
+ supportsIosToolchain = supportsIosToolchain === VOID ? this.z5p_1 : supportsIosToolchain;
256
+ return $super === VOID ? this.a5q(fileSystem, environmentReader, httpClientFactory, processRunner, credentialStore, tokenClient, close, accessTokenCache, pkcePlatform, analyticsConsent, supportsIosToolchain) : $super.a5q.call(this, fileSystem, environmentReader, httpClientFactory, processRunner, credentialStore, tokenClient, close, accessTokenCache, pkcePlatform, analyticsConsent, supportsIosToolchain);
257
+ };
258
+ protoOf(ClientRuntime).toString = function () {
259
+ return 'ClientRuntime(fileSystem=' + toString(this.p5p_1) + ', environmentReader=' + toString(this.q5p_1) + ', httpClientFactory=' + toString(this.r5p_1) + ', processRunner=' + toString(this.s5p_1) + ', credentialStore=' + toString(this.t5p_1) + ', tokenClient=' + toString(this.u5p_1) + ', close=' + toString(this.v5p_1) + ', accessTokenCache=' + toString(this.w5p_1) + ', pkcePlatform=' + toString(this.x5p_1) + ', analyticsConsent=' + toString_0(this.y5p_1) + ', supportsIosToolchain=' + this.z5p_1 + ')';
260
+ };
261
+ protoOf(ClientRuntime).hashCode = function () {
262
+ var result = hashCode(this.p5p_1);
263
+ result = imul(result, 31) + hashCode(this.q5p_1) | 0;
264
+ result = imul(result, 31) + hashCode(this.r5p_1) | 0;
265
+ result = imul(result, 31) + hashCode(this.s5p_1) | 0;
266
+ result = imul(result, 31) + hashCode(this.t5p_1) | 0;
267
+ result = imul(result, 31) + hashCode(this.u5p_1) | 0;
268
+ result = imul(result, 31) + hashCode(this.v5p_1) | 0;
269
+ result = imul(result, 31) + hashCode(this.w5p_1) | 0;
270
+ result = imul(result, 31) + hashCode(this.x5p_1) | 0;
271
+ result = imul(result, 31) + (this.y5p_1 == null ? 0 : hashCode(this.y5p_1)) | 0;
272
+ result = imul(result, 31) + getBooleanHashCode(this.z5p_1) | 0;
273
+ return result;
274
+ };
275
+ protoOf(ClientRuntime).equals = function (other) {
276
+ if (this === other)
277
+ return true;
278
+ if (!(other instanceof ClientRuntime))
279
+ return false;
280
+ if (!equals(this.p5p_1, other.p5p_1))
281
+ return false;
282
+ if (!equals(this.q5p_1, other.q5p_1))
283
+ return false;
284
+ if (!equals(this.r5p_1, other.r5p_1))
285
+ return false;
286
+ if (!equals(this.s5p_1, other.s5p_1))
287
+ return false;
288
+ if (!equals(this.t5p_1, other.t5p_1))
289
+ return false;
290
+ if (!equals(this.u5p_1, other.u5p_1))
291
+ return false;
292
+ if (!equals(this.v5p_1, other.v5p_1))
293
+ return false;
294
+ if (!equals(this.w5p_1, other.w5p_1))
295
+ return false;
296
+ if (!equals(this.x5p_1, other.x5p_1))
297
+ return false;
298
+ if (!equals(this.y5p_1, other.y5p_1))
299
+ return false;
300
+ if (!(this.z5p_1 === other.z5p_1))
301
+ return false;
302
+ return true;
303
+ };
304
+ function UnavailableProcessRunner() {
305
+ }
306
+ protoOf(UnavailableProcessRunner).c5q = function (request, $completion) {
307
+ throw new ProcessLaunchException('External process execution is not configured for this client runtime.');
308
+ };
309
+ protoOf(UnavailableProcessRunner).j5o = function (request, $completion) {
310
+ return this.c5q(request, $completion);
311
+ };
312
+ var UnavailableProcessRunner_instance;
313
+ function UnavailableProcessRunner_getInstance() {
314
+ return UnavailableProcessRunner_instance;
315
+ }
316
+ function EmptyCredentialStore() {
317
+ }
318
+ protoOf(EmptyCredentialStore).d5q = function (apiUrl, $completion) {
319
+ return null;
320
+ };
321
+ protoOf(EmptyCredentialStore).v4x = function (apiUrl, $completion) {
322
+ return this.d5q(apiUrl, $completion);
323
+ };
324
+ protoOf(EmptyCredentialStore).w4x = function (session, $completion) {
325
+ return Unit_instance;
326
+ };
327
+ protoOf(EmptyCredentialStore).x4x = function (apiUrl, $completion) {
328
+ return Unit_instance;
329
+ };
330
+ var EmptyCredentialStore_instance;
331
+ function EmptyCredentialStore_getInstance() {
332
+ return EmptyCredentialStore_instance;
333
+ }
334
+ function UnavailableTokenClient() {
335
+ }
336
+ protoOf(UnavailableTokenClient).q4x = function (apiUrl, code, verifier, redirectUri, $completion) {
337
+ return new Failed(AuthErrorCode_AUTH_REQUIRED_getInstance(), 'Error: user session is not configured.');
338
+ };
339
+ protoOf(UnavailableTokenClient).s4x = function (apiUrl, refreshToken, $completion) {
340
+ return new Failed(AuthErrorCode_AUTH_REQUIRED_getInstance(), 'Error: user session is not configured.');
341
+ };
342
+ protoOf(UnavailableTokenClient).t4x = function (apiUrl, refreshToken, $completion) {
343
+ return new Failed(AuthErrorCode_AUTH_REQUIRED_getInstance(), 'Error: user session is not configured.');
344
+ };
345
+ var UnavailableTokenClient_instance;
346
+ function UnavailableTokenClient_getInstance() {
347
+ return UnavailableTokenClient_instance;
348
+ }
349
+ function withProjectEnvironment($this, context) {
350
+ var tmp;
351
+ try {
352
+ // Inline function 'kotlin.takeIf' call
353
+ var this_0 = context.a5p_1;
354
+ var tmp_0;
355
+ // Inline function 'kotlin.text.isNotBlank' call
356
+ if (!isBlank(this_0)) {
357
+ tmp_0 = this_0;
358
+ } else {
359
+ tmp_0 = null;
360
+ }
361
+ var tmp0_safe_receiver = tmp_0;
362
+ var tmp_1;
363
+ if (tmp0_safe_receiver == null) {
364
+ tmp_1 = null;
365
+ } else {
366
+ // Inline function 'kotlin.let' call
367
+ var tmp0_safe_receiver_0 = $this.f5q_1;
368
+ tmp_1 = tmp0_safe_receiver_0 == null ? null : tmp0_safe_receiver_0.i5q(tmp0_safe_receiver);
369
+ }
370
+ tmp = tmp_1;
371
+ } catch ($p) {
372
+ var tmp_2;
373
+ if ($p instanceof ProjectEnvironmentException) {
374
+ var error = $p;
375
+ return new Failed_2('Error: ' + error.message);
376
+ } else {
377
+ throw $p;
378
+ }
379
+ }
380
+ var environment = tmp;
381
+ return new Found_0(context, environment);
382
+ }
383
+ function ContextResolver(sources, projectEnvironmentLoader) {
384
+ projectEnvironmentLoader = projectEnvironmentLoader === VOID ? null : projectEnvironmentLoader;
385
+ this.e5q_1 = sources;
386
+ this.f5q_1 = projectEnvironmentLoader;
387
+ }
388
+ protoOf(ContextResolver).j5q = function (request) {
389
+ return this.m5q(request.k5q_1, request.l5q_1);
390
+ };
391
+ protoOf(ContextResolver).m5q = function (startingDirectory, designSystemUri) {
392
+ if (!(designSystemUri == null)) {
393
+ var tmp0_elvis_lhs = DesignSystemLink_getInstance().tp(designSystemUri);
394
+ var tmp;
395
+ if (tmp0_elvis_lhs == null) {
396
+ return new Failed_2('Invalid design-system link.', ProjectContextFailure_INVALID_CONTEXT_getInstance());
397
+ } else {
398
+ tmp = tmp0_elvis_lhs;
399
+ }
400
+ var selection = tmp;
401
+ return new Found_0(new ProjectContext(_ProjectId___init__impl__b1fobp(_ProjectId___get_value__impl__lfubnr(selection.r5o_1)), _DesignSystemId___init__impl__6op7ax(_DesignSystemId___get_value__impl__wgtkjx(selection.s5o_1)), _CredentialEnvName___init__impl__w41seg('DSBUILDER_API_KEY'), '', listOfNotNull(selection.u5o_1), CredentialPolicy_AUTO_getInstance(), ContextProvenance_EXPLICIT_LINK_getInstance(), selection.t5o_1));
402
+ }
403
+ var _iterator__ex2g4s = this.e5q_1.l();
404
+ while (_iterator__ex2g4s.m()) {
405
+ var source = _iterator__ex2g4s.n();
406
+ var result = source.q5q(startingDirectory);
407
+ if (result instanceof Failed_0)
408
+ return new Failed_2(result.s5q_1, result.t5q_1);
409
+ else {
410
+ if (result instanceof Found)
411
+ return withProjectEnvironment(this, result.r5q_1);
412
+ else {
413
+ if (!equals(result, NotFound_instance)) {
414
+ noWhenBranchMatchedException();
415
+ }
416
+ }
417
+ }
418
+ }
419
+ return new Failed_2("Error: Design-system context is required. Pass --design-system 'dsbuilder://projects/<project-id>/design-systems/<design-system-id>?version=<version>[&platform=<platform>]', or run `dsbuilder init --project-id <id> --design-system-id <id>`.", ProjectContextFailure_NOT_INITIALIZED_getInstance());
420
+ };
421
+ protoOf(ContextResolver).u5q = function (startingDirectory, designSystemUri, $super) {
422
+ startingDirectory = startingDirectory === VOID ? null : startingDirectory;
423
+ designSystemUri = designSystemUri === VOID ? null : designSystemUri;
424
+ return $super === VOID ? this.m5q(startingDirectory, designSystemUri) : $super.m5q.call(this, startingDirectory, designSystemUri);
425
+ };
426
+ function ContextSource() {
427
+ }
428
+ function NearestProjectConfigContextSource(projectConfigStore) {
429
+ this.v5q_1 = projectConfigStore;
430
+ }
431
+ protoOf(NearestProjectConfigContextSource).q5q = function (startingDirectory) {
432
+ var tmp;
433
+ try {
434
+ var tmp_0;
435
+ // Inline function 'kotlin.text.isNullOrBlank' call
436
+ if (startingDirectory == null || isBlank(startingDirectory)) {
437
+ tmp_0 = this.v5q_1.u5n();
438
+ } else {
439
+ tmp_0 = this.v5q_1.t5n(startingDirectory);
440
+ }
441
+ var context = tmp_0;
442
+ tmp = new Found(toProjectContext(context));
443
+ } catch ($p) {
444
+ var tmp_1;
445
+ if ($p instanceof ProjectNotInitializedException) {
446
+ var exception = $p;
447
+ tmp_1 = NotFound_instance;
448
+ } else {
449
+ if ($p instanceof ProjectConfigException) {
450
+ var exception_0 = $p;
451
+ tmp_1 = new Failed_0('Error: ' + exception_0.message, ProjectContextFailure_INVALID_getInstance());
452
+ } else {
453
+ if ($p instanceof UnknownTargetPlatformException) {
454
+ var exception_1 = $p;
455
+ tmp_1 = new Failed_0('Error: ' + exception_1.message);
456
+ } else {
457
+ throw $p;
458
+ }
459
+ }
460
+ }
461
+ tmp = tmp_1;
462
+ }
463
+ return tmp;
464
+ };
465
+ function Found(context) {
466
+ this.r5q_1 = context;
467
+ }
468
+ protoOf(Found).toString = function () {
469
+ return 'Found(context=' + this.r5q_1.toString() + ')';
470
+ };
471
+ protoOf(Found).hashCode = function () {
472
+ return this.r5q_1.hashCode();
473
+ };
474
+ protoOf(Found).equals = function (other) {
475
+ if (this === other)
476
+ return true;
477
+ if (!(other instanceof Found))
478
+ return false;
479
+ if (!this.r5q_1.equals(other.r5q_1))
480
+ return false;
481
+ return true;
482
+ };
483
+ function NotFound() {
484
+ }
485
+ protoOf(NotFound).toString = function () {
486
+ return 'NotFound';
487
+ };
488
+ protoOf(NotFound).hashCode = function () {
489
+ return 1538853014;
490
+ };
491
+ protoOf(NotFound).equals = function (other) {
492
+ if (this === other)
493
+ return true;
494
+ if (!(other instanceof NotFound))
495
+ return false;
496
+ return true;
497
+ };
498
+ var NotFound_instance;
499
+ function NotFound_getInstance() {
500
+ return NotFound_instance;
501
+ }
502
+ function Failed_0(message, reason) {
503
+ reason = reason === VOID ? ProjectContextFailure_INVALID_getInstance() : reason;
504
+ this.s5q_1 = message;
505
+ this.t5q_1 = reason;
506
+ }
507
+ protoOf(Failed_0).toString = function () {
508
+ return 'Failed(message=' + this.s5q_1 + ', reason=' + this.t5q_1.toString() + ')';
509
+ };
510
+ protoOf(Failed_0).hashCode = function () {
511
+ var result = getStringHashCode(this.s5q_1);
512
+ result = imul(result, 31) + this.t5q_1.hashCode() | 0;
513
+ return result;
514
+ };
515
+ protoOf(Failed_0).equals = function (other) {
516
+ if (this === other)
517
+ return true;
518
+ if (!(other instanceof Failed_0))
519
+ return false;
520
+ if (!(this.s5q_1 === other.s5q_1))
521
+ return false;
522
+ if (!this.t5q_1.equals(other.t5q_1))
523
+ return false;
524
+ return true;
525
+ };
526
+ function coreApplicationModule(runtime) {
527
+ return module_0(VOID, coreApplicationModule$lambda(runtime));
528
+ }
529
+ function coreApplicationModule$lambda$lambda($runtime) {
530
+ return function ($this$single, it) {
531
+ return $runtime;
532
+ };
533
+ }
534
+ function coreApplicationModule$lambda$lambda_0($runtime) {
535
+ return function ($this$single, it) {
536
+ return $runtime.w5p_1;
537
+ };
538
+ }
539
+ function coreApplicationModule$lambda$lambda_1($runtime) {
540
+ return function ($this$single, it) {
541
+ return $runtime.x5p_1;
542
+ };
543
+ }
544
+ function coreApplicationModule$lambda$lambda_2($this$single, it) {
545
+ // Inline function 'org.koin.core.scope.Scope.get' call
546
+ return $this$single.j59(getKClass(ClientRuntime), null, null).p5p_1;
547
+ }
548
+ function coreApplicationModule$lambda$lambda_3($this$single, it) {
549
+ // Inline function 'org.koin.core.scope.Scope.get' call
550
+ return $this$single.j59(getKClass(ClientRuntime), null, null).q5p_1;
551
+ }
552
+ function coreApplicationModule$lambda$lambda_4($this$single, it) {
553
+ // Inline function 'org.koin.core.scope.Scope.get' call
554
+ var tmp = $this$single.j59(getKClass(ClientRuntime), null, null).r5p_1;
555
+ // Inline function 'org.koin.core.scope.Scope.get' call
556
+ var tmp_0 = $this$single.j59(getKClass(CredentialProvider), null, null);
557
+ // Inline function 'org.koin.core.scope.Scope.get' call
558
+ var tmp_1 = $this$single.j59(getKClass(CredentialStore), null, null);
559
+ // Inline function 'org.koin.core.scope.Scope.get' call
560
+ var tmp$ret$3 = $this$single.j59(getKClass(UserAccessTokenCache), null, null);
561
+ return new RefreshingAuthenticatedHttpClientFactory(tmp, tmp_0, tmp_1, tmp$ret$3);
562
+ }
563
+ function coreApplicationModule$lambda$lambda_5($this$single, it) {
564
+ // Inline function 'org.koin.core.scope.Scope.get' call
565
+ return $this$single.j59(getKClass(ClientRuntime), null, null).s5p_1;
566
+ }
567
+ function coreApplicationModule$lambda$lambda_6($this$single, it) {
568
+ // Inline function 'org.koin.core.scope.Scope.get' call
569
+ return $this$single.j59(getKClass(ClientRuntime), null, null).t5p_1;
570
+ }
571
+ function coreApplicationModule$lambda$lambda_7($this$single, it) {
572
+ // Inline function 'org.koin.core.scope.Scope.get' call
573
+ return $this$single.j59(getKClass(ClientRuntime), null, null).u5p_1;
574
+ }
575
+ function coreApplicationModule$lambda$lambda_8($this$single, it) {
576
+ // Inline function 'org.koin.core.scope.Scope.get' call
577
+ var tmp$ret$0 = $this$single.j59(getKClass(CredentialProvider), null, null);
578
+ return UserSessionAccess_init_$Create$(tmp$ret$0);
579
+ }
580
+ function coreApplicationModule$lambda$lambda_9($this$single, it) {
581
+ // Inline function 'org.koin.core.scope.Scope.get' call
582
+ var tmp$ret$0 = $this$single.j59(getKClass(WorkspaceFileSystem), null, null);
583
+ return new ProjectConfigStore(tmp$ret$0);
584
+ }
585
+ function coreApplicationModule$lambda$lambda_10($this$single, it) {
586
+ // Inline function 'org.koin.core.scope.Scope.get' call
587
+ var tmp$ret$0 = $this$single.j59(getKClass(WorkspaceFileSystem), null, null);
588
+ return new ProjectEnvironmentLoader(tmp$ret$0);
589
+ }
590
+ function coreApplicationModule$lambda$lambda_11($this$single, it) {
591
+ // Inline function 'org.koin.core.scope.Scope.get' call
592
+ var tmp$ret$0 = $this$single.j59(getKClass(EnvironmentReader), null, null);
593
+ return new PatResolver(tmp$ret$0);
594
+ }
595
+ function coreApplicationModule$lambda$lambda_12($this$single, it) {
596
+ // Inline function 'org.koin.core.scope.Scope.get' call
597
+ var tmp$ret$0 = $this$single.j59(getKClass(EnvironmentReader), null, null);
598
+ return new ApiUrlResolver(tmp$ret$0);
599
+ }
600
+ function coreApplicationModule$lambda$lambda_13($this$single, it) {
601
+ // Inline function 'org.koin.core.scope.Scope.get' call
602
+ var tmp$ret$0 = $this$single.j59(getKClass(ProjectConfigStore), null, null);
603
+ return new NearestProjectConfigContextSource(tmp$ret$0);
604
+ }
605
+ function coreApplicationModule$lambda$lambda_14($this$single, it) {
606
+ // Inline function 'org.koin.core.scope.Scope.getAll' call
607
+ var tmp = $this$single.k59(getKClass(ContextSource));
608
+ // Inline function 'org.koin.core.scope.Scope.get' call
609
+ var tmp$ret$1 = $this$single.j59(getKClass(ProjectEnvironmentLoader), null, null);
610
+ return new ContextResolver(tmp, tmp$ret$1);
611
+ }
612
+ function coreApplicationModule$lambda$lambda_15($this$single, it) {
613
+ // Inline function 'org.koin.core.scope.Scope.get' call
614
+ var tmp$ret$0 = $this$single.j59(getKClass(ContextResolver), null, null);
615
+ return new LocalProjectContextReader(tmp$ret$0);
616
+ }
617
+ function coreApplicationModule$lambda$lambda_16($this$single, it) {
618
+ // Inline function 'org.koin.core.scope.Scope.get' call
619
+ var tmp$ret$0 = $this$single.j59(getKClass(PatResolver), null, null);
620
+ return new RuntimePersonalAccessTokenProvider(tmp$ret$0);
621
+ }
622
+ function coreApplicationModule$lambda$lambda_17($this$single, it) {
623
+ // Inline function 'org.koin.core.scope.Scope.get' call
624
+ var tmp$ret$0 = $this$single.j59(getKClass(ApiUrlResolver), null, null);
625
+ return new RuntimeProjectApiUrlProvider(tmp$ret$0);
626
+ }
627
+ function coreApplicationModule$lambda$lambda_18($this$single, it) {
628
+ // Inline function 'org.koin.core.scope.Scope.get' call
629
+ var tmp = $this$single.j59(getKClass(PatResolver), null, null);
630
+ // Inline function 'org.koin.core.scope.Scope.get' call
631
+ var tmp_0 = $this$single.j59(getKClass(CredentialStore), null, null);
632
+ // Inline function 'org.koin.core.scope.Scope.get' call
633
+ var tmp_1 = $this$single.j59(getKClass(TokenClient), null, null);
634
+ // Inline function 'org.koin.core.scope.Scope.get' call
635
+ var tmp_2 = $this$single.j59(getKClass(EnvironmentReader), null, null);
636
+ // Inline function 'org.koin.core.scope.Scope.get' call
637
+ var tmp$ret$4 = $this$single.j59(getKClass(UserAccessTokenCache), null, null);
638
+ return new RuntimeCredentialProvider(tmp, tmp_0, tmp_1, tmp_2, VOID, tmp$ret$4);
639
+ }
640
+ function coreApplicationModule$lambda($runtime) {
641
+ return function ($this$module) {
642
+ // Inline function 'org.koin.core.module.Module.single' call
643
+ // Inline function 'org.koin.core.module._singleInstanceFactory' call
644
+ var definition = coreApplicationModule$lambda$lambda($runtime);
645
+ var scopeQualifier = Companion_getInstance().u56_1;
646
+ // Inline function 'org.koin.core.definition._createDefinition' call
647
+ var kind = Kind_Singleton_getInstance();
648
+ var secondaryTypes = emptyList();
649
+ var def = new BeanDefinition(scopeQualifier, getKClass(ClientRuntime), null, definition, kind, secondaryTypes);
650
+ var factory = new SingleInstanceFactory(def);
651
+ $this$module.k58(factory);
652
+ if (false || $this$module.e58_1) {
653
+ $this$module.m58(factory);
654
+ }
655
+ new KoinDefinition($this$module, factory);
656
+ // Inline function 'org.koin.core.module.Module.single' call
657
+ // Inline function 'org.koin.core.module._singleInstanceFactory' call
658
+ var definition_0 = coreApplicationModule$lambda$lambda_0($runtime);
659
+ var scopeQualifier_0 = Companion_getInstance().u56_1;
660
+ // Inline function 'org.koin.core.definition._createDefinition' call
661
+ var kind_0 = Kind_Singleton_getInstance();
662
+ var secondaryTypes_0 = emptyList();
663
+ var def_0 = new BeanDefinition(scopeQualifier_0, getKClass(UserAccessTokenCache), null, definition_0, kind_0, secondaryTypes_0);
664
+ var factory_0 = new SingleInstanceFactory(def_0);
665
+ $this$module.k58(factory_0);
666
+ if (false || $this$module.e58_1) {
667
+ $this$module.m58(factory_0);
668
+ }
669
+ new KoinDefinition($this$module, factory_0);
670
+ // Inline function 'org.koin.core.module.Module.single' call
671
+ // Inline function 'org.koin.core.module._singleInstanceFactory' call
672
+ var definition_1 = coreApplicationModule$lambda$lambda_1($runtime);
673
+ var scopeQualifier_1 = Companion_getInstance().u56_1;
674
+ // Inline function 'org.koin.core.definition._createDefinition' call
675
+ var kind_1 = Kind_Singleton_getInstance();
676
+ var secondaryTypes_1 = emptyList();
677
+ var def_1 = new BeanDefinition(scopeQualifier_1, getKClass(PkcePlatform), null, definition_1, kind_1, secondaryTypes_1);
678
+ var factory_1 = new SingleInstanceFactory(def_1);
679
+ $this$module.k58(factory_1);
680
+ if (false || $this$module.e58_1) {
681
+ $this$module.m58(factory_1);
682
+ }
683
+ new KoinDefinition($this$module, factory_1);
684
+ // Inline function 'org.koin.core.module.Module.single' call
685
+ // Inline function 'org.koin.core.module._singleInstanceFactory' call
686
+ var definition_2 = coreApplicationModule$lambda$lambda_2;
687
+ var scopeQualifier_2 = Companion_getInstance().u56_1;
688
+ // Inline function 'org.koin.core.definition._createDefinition' call
689
+ var kind_2 = Kind_Singleton_getInstance();
690
+ var secondaryTypes_2 = emptyList();
691
+ var def_2 = new BeanDefinition(scopeQualifier_2, getKClass(WorkspaceFileSystem), null, definition_2, kind_2, secondaryTypes_2);
692
+ var factory_2 = new SingleInstanceFactory(def_2);
693
+ $this$module.k58(factory_2);
694
+ if (false || $this$module.e58_1) {
695
+ $this$module.m58(factory_2);
696
+ }
697
+ new KoinDefinition($this$module, factory_2);
698
+ // Inline function 'org.koin.core.module.Module.single' call
699
+ // Inline function 'org.koin.core.module._singleInstanceFactory' call
700
+ var definition_3 = coreApplicationModule$lambda$lambda_3;
701
+ var scopeQualifier_3 = Companion_getInstance().u56_1;
702
+ // Inline function 'org.koin.core.definition._createDefinition' call
703
+ var kind_3 = Kind_Singleton_getInstance();
704
+ var secondaryTypes_3 = emptyList();
705
+ var def_3 = new BeanDefinition(scopeQualifier_3, getKClass(EnvironmentReader), null, definition_3, kind_3, secondaryTypes_3);
706
+ var factory_3 = new SingleInstanceFactory(def_3);
707
+ $this$module.k58(factory_3);
708
+ if (false || $this$module.e58_1) {
709
+ $this$module.m58(factory_3);
710
+ }
711
+ new KoinDefinition($this$module, factory_3);
712
+ // Inline function 'org.koin.core.module.Module.single' call
713
+ // Inline function 'org.koin.core.module._singleInstanceFactory' call
714
+ var definition_4 = coreApplicationModule$lambda$lambda_4;
715
+ var scopeQualifier_4 = Companion_getInstance().u56_1;
716
+ // Inline function 'org.koin.core.definition._createDefinition' call
717
+ var kind_4 = Kind_Singleton_getInstance();
718
+ var secondaryTypes_4 = emptyList();
719
+ var def_4 = new BeanDefinition(scopeQualifier_4, getKClass(AuthenticatedHttpClientFactory), null, definition_4, kind_4, secondaryTypes_4);
720
+ var factory_4 = new SingleInstanceFactory(def_4);
721
+ $this$module.k58(factory_4);
722
+ if (false || $this$module.e58_1) {
723
+ $this$module.m58(factory_4);
724
+ }
725
+ new KoinDefinition($this$module, factory_4);
726
+ // Inline function 'org.koin.core.module.Module.single' call
727
+ // Inline function 'org.koin.core.module._singleInstanceFactory' call
728
+ var definition_5 = coreApplicationModule$lambda$lambda_5;
729
+ var scopeQualifier_5 = Companion_getInstance().u56_1;
730
+ // Inline function 'org.koin.core.definition._createDefinition' call
731
+ var kind_5 = Kind_Singleton_getInstance();
732
+ var secondaryTypes_5 = emptyList();
733
+ var def_5 = new BeanDefinition(scopeQualifier_5, getKClass(ProcessRunner), null, definition_5, kind_5, secondaryTypes_5);
734
+ var factory_5 = new SingleInstanceFactory(def_5);
735
+ $this$module.k58(factory_5);
736
+ if (false || $this$module.e58_1) {
737
+ $this$module.m58(factory_5);
738
+ }
739
+ new KoinDefinition($this$module, factory_5);
740
+ // Inline function 'org.koin.core.module.Module.single' call
741
+ // Inline function 'org.koin.core.module._singleInstanceFactory' call
742
+ var definition_6 = coreApplicationModule$lambda$lambda_6;
743
+ var scopeQualifier_6 = Companion_getInstance().u56_1;
744
+ // Inline function 'org.koin.core.definition._createDefinition' call
745
+ var kind_6 = Kind_Singleton_getInstance();
746
+ var secondaryTypes_6 = emptyList();
747
+ var def_6 = new BeanDefinition(scopeQualifier_6, getKClass(CredentialStore), null, definition_6, kind_6, secondaryTypes_6);
748
+ var factory_6 = new SingleInstanceFactory(def_6);
749
+ $this$module.k58(factory_6);
750
+ if (false || $this$module.e58_1) {
751
+ $this$module.m58(factory_6);
752
+ }
753
+ new KoinDefinition($this$module, factory_6);
754
+ // Inline function 'org.koin.core.module.Module.single' call
755
+ // Inline function 'org.koin.core.module._singleInstanceFactory' call
756
+ var definition_7 = coreApplicationModule$lambda$lambda_7;
757
+ var scopeQualifier_7 = Companion_getInstance().u56_1;
758
+ // Inline function 'org.koin.core.definition._createDefinition' call
759
+ var kind_7 = Kind_Singleton_getInstance();
760
+ var secondaryTypes_7 = emptyList();
761
+ var def_7 = new BeanDefinition(scopeQualifier_7, getKClass(TokenClient), null, definition_7, kind_7, secondaryTypes_7);
762
+ var factory_7 = new SingleInstanceFactory(def_7);
763
+ $this$module.k58(factory_7);
764
+ if (false || $this$module.e58_1) {
765
+ $this$module.m58(factory_7);
766
+ }
767
+ new KoinDefinition($this$module, factory_7);
768
+ // Inline function 'org.koin.core.module.Module.single' call
769
+ // Inline function 'org.koin.core.module._singleInstanceFactory' call
770
+ var definition_8 = coreApplicationModule$lambda$lambda_8;
771
+ var scopeQualifier_8 = Companion_getInstance().u56_1;
772
+ // Inline function 'org.koin.core.definition._createDefinition' call
773
+ var kind_8 = Kind_Singleton_getInstance();
774
+ var secondaryTypes_8 = emptyList();
775
+ var def_8 = new BeanDefinition(scopeQualifier_8, getKClass(UserSessionAccess), null, definition_8, kind_8, secondaryTypes_8);
776
+ var factory_8 = new SingleInstanceFactory(def_8);
777
+ $this$module.k58(factory_8);
778
+ if (false || $this$module.e58_1) {
779
+ $this$module.m58(factory_8);
780
+ }
781
+ new KoinDefinition($this$module, factory_8);
782
+ // Inline function 'org.koin.core.module.Module.single' call
783
+ // Inline function 'org.koin.core.module._singleInstanceFactory' call
784
+ var definition_9 = coreApplicationModule$lambda$lambda_9;
785
+ var scopeQualifier_9 = Companion_getInstance().u56_1;
786
+ // Inline function 'org.koin.core.definition._createDefinition' call
787
+ var kind_9 = Kind_Singleton_getInstance();
788
+ var secondaryTypes_9 = emptyList();
789
+ var def_9 = new BeanDefinition(scopeQualifier_9, getKClass(ProjectConfigStore), null, definition_9, kind_9, secondaryTypes_9);
790
+ var factory_9 = new SingleInstanceFactory(def_9);
791
+ $this$module.k58(factory_9);
792
+ if (false || $this$module.e58_1) {
793
+ $this$module.m58(factory_9);
794
+ }
795
+ new KoinDefinition($this$module, factory_9);
796
+ // Inline function 'org.koin.core.module.Module.single' call
797
+ // Inline function 'org.koin.core.module._singleInstanceFactory' call
798
+ var definition_10 = coreApplicationModule$lambda$lambda_10;
799
+ var scopeQualifier_10 = Companion_getInstance().u56_1;
800
+ // Inline function 'org.koin.core.definition._createDefinition' call
801
+ var kind_10 = Kind_Singleton_getInstance();
802
+ var secondaryTypes_10 = emptyList();
803
+ var def_10 = new BeanDefinition(scopeQualifier_10, getKClass(ProjectEnvironmentLoader), null, definition_10, kind_10, secondaryTypes_10);
804
+ var factory_10 = new SingleInstanceFactory(def_10);
805
+ $this$module.k58(factory_10);
806
+ if (false || $this$module.e58_1) {
807
+ $this$module.m58(factory_10);
808
+ }
809
+ new KoinDefinition($this$module, factory_10);
810
+ // Inline function 'org.koin.core.module.Module.single' call
811
+ // Inline function 'org.koin.core.module._singleInstanceFactory' call
812
+ var definition_11 = coreApplicationModule$lambda$lambda_11;
813
+ var scopeQualifier_11 = Companion_getInstance().u56_1;
814
+ // Inline function 'org.koin.core.definition._createDefinition' call
815
+ var kind_11 = Kind_Singleton_getInstance();
816
+ var secondaryTypes_11 = emptyList();
817
+ var def_11 = new BeanDefinition(scopeQualifier_11, getKClass(PatResolver), null, definition_11, kind_11, secondaryTypes_11);
818
+ var factory_11 = new SingleInstanceFactory(def_11);
819
+ $this$module.k58(factory_11);
820
+ if (false || $this$module.e58_1) {
821
+ $this$module.m58(factory_11);
822
+ }
823
+ new KoinDefinition($this$module, factory_11);
824
+ // Inline function 'org.koin.core.module.Module.single' call
825
+ // Inline function 'org.koin.core.module._singleInstanceFactory' call
826
+ var definition_12 = coreApplicationModule$lambda$lambda_12;
827
+ var scopeQualifier_12 = Companion_getInstance().u56_1;
828
+ // Inline function 'org.koin.core.definition._createDefinition' call
829
+ var kind_12 = Kind_Singleton_getInstance();
830
+ var secondaryTypes_12 = emptyList();
831
+ var def_12 = new BeanDefinition(scopeQualifier_12, getKClass(ApiUrlResolver), null, definition_12, kind_12, secondaryTypes_12);
832
+ var factory_12 = new SingleInstanceFactory(def_12);
833
+ $this$module.k58(factory_12);
834
+ if (false || $this$module.e58_1) {
835
+ $this$module.m58(factory_12);
836
+ }
837
+ new KoinDefinition($this$module, factory_12);
838
+ // Inline function 'org.koin.core.module.Module.single' call
839
+ // Inline function 'org.koin.core.module._singleInstanceFactory' call
840
+ var definition_13 = coreApplicationModule$lambda$lambda_13;
841
+ var scopeQualifier_13 = Companion_getInstance().u56_1;
842
+ // Inline function 'org.koin.core.definition._createDefinition' call
843
+ var kind_13 = Kind_Singleton_getInstance();
844
+ var secondaryTypes_13 = emptyList();
845
+ var def_13 = new BeanDefinition(scopeQualifier_13, getKClass(ContextSource), null, definition_13, kind_13, secondaryTypes_13);
846
+ var factory_13 = new SingleInstanceFactory(def_13);
847
+ $this$module.k58(factory_13);
848
+ if (false || $this$module.e58_1) {
849
+ $this$module.m58(factory_13);
850
+ }
851
+ new KoinDefinition($this$module, factory_13);
852
+ // Inline function 'org.koin.core.module.Module.single' call
853
+ // Inline function 'org.koin.core.module._singleInstanceFactory' call
854
+ var definition_14 = coreApplicationModule$lambda$lambda_14;
855
+ var scopeQualifier_14 = Companion_getInstance().u56_1;
856
+ // Inline function 'org.koin.core.definition._createDefinition' call
857
+ var kind_14 = Kind_Singleton_getInstance();
858
+ var secondaryTypes_14 = emptyList();
859
+ var def_14 = new BeanDefinition(scopeQualifier_14, getKClass(ContextResolver), null, definition_14, kind_14, secondaryTypes_14);
860
+ var factory_14 = new SingleInstanceFactory(def_14);
861
+ $this$module.k58(factory_14);
862
+ if (false || $this$module.e58_1) {
863
+ $this$module.m58(factory_14);
864
+ }
865
+ new KoinDefinition($this$module, factory_14);
866
+ // Inline function 'org.koin.core.module.Module.single' call
867
+ // Inline function 'org.koin.core.module._singleInstanceFactory' call
868
+ var definition_15 = coreApplicationModule$lambda$lambda_15;
869
+ var scopeQualifier_15 = Companion_getInstance().u56_1;
870
+ // Inline function 'org.koin.core.definition._createDefinition' call
871
+ var kind_15 = Kind_Singleton_getInstance();
872
+ var secondaryTypes_15 = emptyList();
873
+ var def_15 = new BeanDefinition(scopeQualifier_15, getKClass(ProjectContextReader), null, definition_15, kind_15, secondaryTypes_15);
874
+ var factory_15 = new SingleInstanceFactory(def_15);
875
+ $this$module.k58(factory_15);
876
+ if (false || $this$module.e58_1) {
877
+ $this$module.m58(factory_15);
878
+ }
879
+ new KoinDefinition($this$module, factory_15);
880
+ // Inline function 'org.koin.core.module.Module.single' call
881
+ // Inline function 'org.koin.core.module._singleInstanceFactory' call
882
+ var definition_16 = coreApplicationModule$lambda$lambda_16;
883
+ var scopeQualifier_16 = Companion_getInstance().u56_1;
884
+ // Inline function 'org.koin.core.definition._createDefinition' call
885
+ var kind_16 = Kind_Singleton_getInstance();
886
+ var secondaryTypes_16 = emptyList();
887
+ var def_16 = new BeanDefinition(scopeQualifier_16, getKClass(PersonalAccessTokenProvider), null, definition_16, kind_16, secondaryTypes_16);
888
+ var factory_16 = new SingleInstanceFactory(def_16);
889
+ $this$module.k58(factory_16);
890
+ if (false || $this$module.e58_1) {
891
+ $this$module.m58(factory_16);
892
+ }
893
+ new KoinDefinition($this$module, factory_16);
894
+ // Inline function 'org.koin.core.module.Module.single' call
895
+ // Inline function 'org.koin.core.module._singleInstanceFactory' call
896
+ var definition_17 = coreApplicationModule$lambda$lambda_17;
897
+ var scopeQualifier_17 = Companion_getInstance().u56_1;
898
+ // Inline function 'org.koin.core.definition._createDefinition' call
899
+ var kind_17 = Kind_Singleton_getInstance();
900
+ var secondaryTypes_17 = emptyList();
901
+ var def_17 = new BeanDefinition(scopeQualifier_17, getKClass(ProjectApiUrlProvider), null, definition_17, kind_17, secondaryTypes_17);
902
+ var factory_17 = new SingleInstanceFactory(def_17);
903
+ $this$module.k58(factory_17);
904
+ if (false || $this$module.e58_1) {
905
+ $this$module.m58(factory_17);
906
+ }
907
+ new KoinDefinition($this$module, factory_17);
908
+ // Inline function 'org.koin.core.module.Module.single' call
909
+ // Inline function 'org.koin.core.module._singleInstanceFactory' call
910
+ var definition_18 = coreApplicationModule$lambda$lambda_18;
911
+ var scopeQualifier_18 = Companion_getInstance().u56_1;
912
+ // Inline function 'org.koin.core.definition._createDefinition' call
913
+ var kind_18 = Kind_Singleton_getInstance();
914
+ var secondaryTypes_18 = emptyList();
915
+ var def_18 = new BeanDefinition(scopeQualifier_18, getKClass(CredentialProvider), null, definition_18, kind_18, secondaryTypes_18);
916
+ var factory_18 = new SingleInstanceFactory(def_18);
917
+ $this$module.k58(factory_18);
918
+ if (false || $this$module.e58_1) {
919
+ $this$module.m58(factory_18);
920
+ }
921
+ new KoinDefinition($this$module, factory_18);
922
+ return Unit_instance;
923
+ };
924
+ }
925
+ function DesignSystemLink() {
926
+ DesignSystemLink_instance = this;
927
+ this.n5q_1 = 'dsbuilder://projects/';
928
+ this.o5q_1 = Regex_init_$Create$('[A-Za-z0-9][A-Za-z0-9_-]*');
929
+ this.p5q_1 = Regex_init_$Create$('[A-Za-z0-9][A-Za-z0-9._+\\-]*');
930
+ }
931
+ protoOf(DesignSystemLink).tp = function (uri) {
932
+ if (!startsWith(uri, 'dsbuilder://projects/') || contains(uri, _Char___init__impl__6a9atx(35)) || contains(uri, _Char___init__impl__6a9atx(64)))
933
+ return null;
934
+ var pieces = split(removePrefix(uri, 'dsbuilder://projects/'), charArrayOf([_Char___init__impl__6a9atx(63)]), VOID, 3);
935
+ if (!(pieces.o() === 2))
936
+ return null;
937
+ var path = split(pieces.p(0), charArrayOf([_Char___init__impl__6a9atx(47)]));
938
+ if (!(path.o() === 3) || !(path.p(1) === 'design-systems'))
939
+ return null;
940
+ var tmp0 = path.p(0);
941
+ // Inline function 'kotlin.takeIf' call
942
+ var tmp;
943
+ if (this.o5q_1.ld(tmp0)) {
944
+ tmp = tmp0;
945
+ } else {
946
+ tmp = null;
947
+ }
948
+ var tmp0_elvis_lhs = tmp;
949
+ var tmp_0;
950
+ if (tmp0_elvis_lhs == null) {
951
+ return null;
952
+ } else {
953
+ tmp_0 = tmp0_elvis_lhs;
954
+ }
955
+ var projectId = tmp_0;
956
+ var tmp0_0 = path.p(2);
957
+ // Inline function 'kotlin.takeIf' call
958
+ var tmp_1;
959
+ if (this.o5q_1.ld(tmp0_0)) {
960
+ tmp_1 = tmp0_0;
961
+ } else {
962
+ tmp_1 = null;
963
+ }
964
+ var tmp1_elvis_lhs = tmp_1;
965
+ var tmp_2;
966
+ if (tmp1_elvis_lhs == null) {
967
+ return null;
968
+ } else {
969
+ tmp_2 = tmp1_elvis_lhs;
970
+ }
971
+ var designSystemId = tmp_2;
972
+ // Inline function 'kotlin.collections.map' call
973
+ var this_0 = split(pieces.p(1), charArrayOf([_Char___init__impl__6a9atx(38)]));
974
+ // Inline function 'kotlin.collections.mapTo' call
975
+ var destination = ArrayList_init_$Create$(collectionSizeOrDefault(this_0, 10));
976
+ var _iterator__ex2g4s = this_0.l();
977
+ while (_iterator__ex2g4s.m()) {
978
+ var item = _iterator__ex2g4s.n();
979
+ var pair = split(item, charArrayOf([_Char___init__impl__6a9atx(61)]), VOID, 3);
980
+ if (!(pair.o() === 2))
981
+ return null;
982
+ var tmp$ret$4 = to(pair.p(0), pair.p(1));
983
+ destination.j(tmp$ret$4);
984
+ }
985
+ var pairs = destination;
986
+ // Inline function 'kotlin.collections.map' call
987
+ // Inline function 'kotlin.collections.mapTo' call
988
+ var destination_0 = ArrayList_init_$Create$(collectionSizeOrDefault(pairs, 10));
989
+ var _iterator__ex2g4s_0 = pairs.l();
990
+ while (_iterator__ex2g4s_0.m()) {
991
+ var item_0 = _iterator__ex2g4s_0.n();
992
+ var tmp$ret$7 = item_0.gh_1;
993
+ destination_0.j(tmp$ret$7);
994
+ }
995
+ var keys = sorted(destination_0);
996
+ if (!listOf_0([listOf('version'), listOf_0(['platform', 'version'])]).t(keys))
997
+ return null;
998
+ var values = toMap(pairs);
999
+ var tmp2_safe_receiver = values.c2('version');
1000
+ var tmp_3;
1001
+ if (tmp2_safe_receiver == null) {
1002
+ tmp_3 = null;
1003
+ } else {
1004
+ // Inline function 'kotlin.takeIf' call
1005
+ var tmp_4;
1006
+ if (this.p5q_1.ld(tmp2_safe_receiver)) {
1007
+ tmp_4 = tmp2_safe_receiver;
1008
+ } else {
1009
+ tmp_4 = null;
1010
+ }
1011
+ tmp_3 = tmp_4;
1012
+ }
1013
+ var tmp3_elvis_lhs = tmp_3;
1014
+ var tmp_5;
1015
+ if (tmp3_elvis_lhs == null) {
1016
+ return null;
1017
+ } else {
1018
+ tmp_5 = tmp3_elvis_lhs;
1019
+ }
1020
+ var selectedVersion = tmp_5;
1021
+ var tmp4_safe_receiver = values.c2('platform');
1022
+ var tmp_6;
1023
+ if (tmp4_safe_receiver == null) {
1024
+ tmp_6 = null;
1025
+ } else {
1026
+ // Inline function 'kotlin.let' call
1027
+ var tmp0_elvis_lhs_0 = Companion_getInstance_0().o5p(tmp4_safe_receiver);
1028
+ var tmp_7;
1029
+ if (tmp0_elvis_lhs_0 == null) {
1030
+ return null;
1031
+ } else {
1032
+ tmp_7 = tmp0_elvis_lhs_0;
1033
+ }
1034
+ tmp_6 = tmp_7;
1035
+ }
1036
+ var platform = tmp_6;
1037
+ return new DesignSystemSelection(_ProjectId___init__impl__b1fobp(projectId), _DesignSystemId___init__impl__6op7ax(designSystemId), selectedVersion, platform);
1038
+ };
1039
+ protoOf(DesignSystemLink).w5q = function (selection) {
1040
+ var tmp = 'dsbuilder://projects/' + _ProjectId___get_value__impl__lfubnr(selection.r5o_1) + '/design-systems/' + _DesignSystemId___get_value__impl__wgtkjx(selection.s5o_1) + ('?version=' + selection.t5o_1);
1041
+ var tmp0_safe_receiver = selection.u5o_1;
1042
+ var tmp_0;
1043
+ if (tmp0_safe_receiver == null) {
1044
+ tmp_0 = null;
1045
+ } else {
1046
+ // Inline function 'kotlin.let' call
1047
+ tmp_0 = '&platform=' + tmp0_safe_receiver.m5p_1;
1048
+ }
1049
+ var tmp1_elvis_lhs = tmp_0;
1050
+ var link = tmp + (tmp1_elvis_lhs == null ? '' : tmp1_elvis_lhs);
1051
+ // Inline function 'kotlin.require' call
1052
+ if (!equals(this.tp(link), selection)) {
1053
+ var message = 'Selection cannot be represented as a design-system link.';
1054
+ throw IllegalArgumentException_init_$Create$(toString(message));
1055
+ }
1056
+ return link;
1057
+ };
1058
+ var DesignSystemLink_instance;
1059
+ function DesignSystemLink_getInstance() {
1060
+ if (DesignSystemLink_instance == null)
1061
+ new DesignSystemLink();
1062
+ return DesignSystemLink_instance;
1063
+ }
1064
+ function DraftEditOptions(idempotencyKey, version, baseRevision) {
1065
+ version = version === VOID ? null : version;
1066
+ baseRevision = baseRevision === VOID ? null : baseRevision;
1067
+ this.x5q_1 = idempotencyKey;
1068
+ this.y5q_1 = version;
1069
+ this.z5q_1 = baseRevision;
1070
+ }
1071
+ protoOf(DraftEditOptions).toString = function () {
1072
+ return 'DraftEditOptions(idempotencyKey=' + this.x5q_1 + ', version=' + this.y5q_1 + ', baseRevision=' + toString_0(this.z5q_1) + ')';
1073
+ };
1074
+ protoOf(DraftEditOptions).hashCode = function () {
1075
+ var result = getStringHashCode(this.x5q_1);
1076
+ result = imul(result, 31) + (this.y5q_1 == null ? 0 : getStringHashCode(this.y5q_1)) | 0;
1077
+ result = imul(result, 31) + (this.z5q_1 == null ? 0 : this.z5q_1.hashCode()) | 0;
1078
+ return result;
1079
+ };
1080
+ protoOf(DraftEditOptions).equals = function (other) {
1081
+ if (this === other)
1082
+ return true;
1083
+ if (!(other instanceof DraftEditOptions))
1084
+ return false;
1085
+ if (!(this.x5q_1 === other.x5q_1))
1086
+ return false;
1087
+ if (!(this.y5q_1 == other.y5q_1))
1088
+ return false;
1089
+ if (!equals(this.z5q_1, other.z5q_1))
1090
+ return false;
1091
+ return true;
1092
+ };
1093
+ function Executed(response, projectId, designSystemId, idempotencyKey) {
1094
+ this.a5r_1 = response;
1095
+ this.b5r_1 = projectId;
1096
+ this.c5r_1 = designSystemId;
1097
+ this.d5r_1 = idempotencyKey;
1098
+ }
1099
+ protoOf(Executed).toString = function () {
1100
+ return 'Executed(response=' + toString(this.a5r_1) + ', projectId=' + this.b5r_1 + ', designSystemId=' + this.c5r_1 + ', idempotencyKey=' + this.d5r_1 + ')';
1101
+ };
1102
+ protoOf(Executed).hashCode = function () {
1103
+ var result = hashCode(this.a5r_1);
1104
+ result = imul(result, 31) + getStringHashCode(this.b5r_1) | 0;
1105
+ result = imul(result, 31) + getStringHashCode(this.c5r_1) | 0;
1106
+ result = imul(result, 31) + (this.d5r_1 == null ? 0 : getStringHashCode(this.d5r_1)) | 0;
1107
+ return result;
1108
+ };
1109
+ protoOf(Executed).equals = function (other) {
1110
+ if (this === other)
1111
+ return true;
1112
+ if (!(other instanceof Executed))
1113
+ return false;
1114
+ if (!equals(this.a5r_1, other.a5r_1))
1115
+ return false;
1116
+ if (!(this.b5r_1 === other.b5r_1))
1117
+ return false;
1118
+ if (!(this.c5r_1 === other.c5r_1))
1119
+ return false;
1120
+ if (!(this.d5r_1 == other.d5r_1))
1121
+ return false;
1122
+ return true;
1123
+ };
1124
+ function Failed_1(code, message) {
1125
+ this.e5r_1 = code;
1126
+ this.f5r_1 = message;
1127
+ }
1128
+ protoOf(Failed_1).toString = function () {
1129
+ return 'Failed(code=' + this.e5r_1 + ', message=' + this.f5r_1 + ')';
1130
+ };
1131
+ protoOf(Failed_1).hashCode = function () {
1132
+ var result = getStringHashCode(this.e5r_1);
1133
+ result = imul(result, 31) + getStringHashCode(this.f5r_1) | 0;
1134
+ return result;
1135
+ };
1136
+ protoOf(Failed_1).equals = function (other) {
1137
+ if (this === other)
1138
+ return true;
1139
+ if (!(other instanceof Failed_1))
1140
+ return false;
1141
+ if (!(this.e5r_1 === other.e5r_1))
1142
+ return false;
1143
+ if (!(this.f5r_1 === other.f5r_1))
1144
+ return false;
1145
+ return true;
1146
+ };
1147
+ function execute($this, version, key, request, operation, $completion) {
1148
+ var tmp = new $executeCOROUTINE$($this, version, key, request, operation, $completion);
1149
+ tmp.y8_1 = Unit_instance;
1150
+ tmp.z8_1 = null;
1151
+ return tmp.e9();
1152
+ }
1153
+ function $executeCOROUTINE$(_this__u8e3s4, version, key, request, operation, resultContinuation) {
1154
+ CoroutineImpl.call(this, resultContinuation);
1155
+ this.o5r_1 = _this__u8e3s4;
1156
+ this.p5r_1 = version;
1157
+ this.q5r_1 = key;
1158
+ this.r5r_1 = request;
1159
+ this.s5r_1 = operation;
1160
+ }
1161
+ protoOf($executeCOROUTINE$).e9 = function () {
1162
+ var suspendResult = this.y8_1;
1163
+ $sm: do
1164
+ try {
1165
+ var tmp = this.w8_1;
1166
+ switch (tmp) {
1167
+ case 0:
1168
+ this.x8_1 = 5;
1169
+ this.w8_1 = 1;
1170
+ suspendResult = this.o5r_1.w5r_1.a5s(this.r5r_1, this);
1171
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
1172
+ return suspendResult;
1173
+ }
1174
+
1175
+ continue $sm;
1176
+ case 1:
1177
+ this.v5r_1 = suspendResult;
1178
+ var tmp_0 = this.v5r_1;
1179
+ if (tmp_0 instanceof Failed_4) {
1180
+ this.t5r_1 = new Failed_1(this.v5r_1.e5s_1.n2_1, this.v5r_1.f5s_1);
1181
+ this.w8_1 = 4;
1182
+ continue $sm;
1183
+ } else {
1184
+ var tmp_1 = this.v5r_1;
1185
+ if (tmp_1 instanceof Resolved) {
1186
+ var tmp0_elvis_lhs = this.p5r_1;
1187
+ var tmp1_elvis_lhs = tmp0_elvis_lhs == null ? this.v5r_1.b5s_1.e5p_1 : tmp0_elvis_lhs;
1188
+ var effectiveVersion = tmp1_elvis_lhs == null ? 'draft' : tmp1_elvis_lhs;
1189
+ if (!(effectiveVersion === 'draft')) {
1190
+ var tmp_2 = this;
1191
+ tmp_2.u5r_1 = new Failed_1('READ_ONLY_VERSION', 'Editor operations require draft.');
1192
+ this.w8_1 = 3;
1193
+ continue $sm;
1194
+ } else {
1195
+ this.w8_1 = 2;
1196
+ suspendResult = this.s5r_1(this.v5r_1, this);
1197
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
1198
+ return suspendResult;
1199
+ }
1200
+ continue $sm;
1201
+ }
1202
+ } else {
1203
+ var tmp_3 = this;
1204
+ noWhenBranchMatchedException();
1205
+ }
1206
+ }
1207
+
1208
+ break;
1209
+ case 2:
1210
+ var ARGUMENT = suspendResult;
1211
+ this.u5r_1 = new Executed(ARGUMENT, _ProjectId___get_value__impl__lfubnr(this.v5r_1.b5s_1.x5o_1), _DesignSystemId___get_value__impl__wgtkjx(this.v5r_1.b5s_1.y5o_1), this.q5r_1);
1212
+ this.w8_1 = 3;
1213
+ continue $sm;
1214
+ case 3:
1215
+ this.t5r_1 = this.u5r_1;
1216
+ this.w8_1 = 4;
1217
+ continue $sm;
1218
+ case 4:
1219
+ return this.t5r_1;
1220
+ case 5:
1221
+ throw this.z8_1;
1222
+ }
1223
+ } catch ($p) {
1224
+ var e = $p;
1225
+ if (this.x8_1 === 5) {
1226
+ throw e;
1227
+ } else {
1228
+ this.w8_1 = this.x8_1;
1229
+ this.z8_1 = e;
1230
+ }
1231
+ }
1232
+ while (true);
1233
+ };
1234
+ function DraftOperationRunner(resolver) {
1235
+ this.w5r_1 = resolver;
1236
+ }
1237
+ protoOf(DraftOperationRunner).g5s = function (options, request, operation, $completion) {
1238
+ var tmp;
1239
+ if (isBlank(options.x5q_1)) {
1240
+ tmp = true;
1241
+ } else {
1242
+ var tmp0_safe_receiver = options.z5q_1;
1243
+ var tmp_0;
1244
+ if (tmp0_safe_receiver == null) {
1245
+ tmp_0 = null;
1246
+ } else {
1247
+ // Inline function 'kotlin.let' call
1248
+ tmp_0 = compare(tmp0_safe_receiver, new Long(0, 0)) < 0;
1249
+ }
1250
+ tmp = tmp_0 === true;
1251
+ }
1252
+ if (tmp) {
1253
+ return new Failed_1('VALIDATION_FAILED', 'A key and non-negative revision are required.');
1254
+ }
1255
+ return execute(this, options.y5q_1, options.x5q_1, request, operation, $completion);
1256
+ };
1257
+ protoOf(DraftOperationRunner).h5s = function (version, request, operation, $completion) {
1258
+ return execute(this, version, null, request, operation, $completion);
1259
+ };
1260
+ function LocalProjectContextReader(contextResolver) {
1261
+ this.i5s_1 = contextResolver;
1262
+ }
1263
+ protoOf(LocalProjectContextReader).j5s = function (startingDirectory) {
1264
+ return this.i5s_1.u5q(startingDirectory);
1265
+ };
1266
+ protoOf(LocalProjectContextReader).k5s = function (request) {
1267
+ return this.i5s_1.m5q(request.k5q_1, request.l5q_1);
1268
+ };
1269
+ function toProjectContext(_this__u8e3s4) {
1270
+ var tmp1_projectId = _ProjectId___init__impl__b1fobp(_this__u8e3s4.b5o_1.y5m_1);
1271
+ var tmp2_designSystemId = _DesignSystemId___init__impl__6op7ax(_this__u8e3s4.b5o_1.z5m_1);
1272
+ var tmp3_credentialEnvName = _CredentialEnvName___init__impl__w41seg(_this__u8e3s4.b5o_1.a5n_1.m5n_1);
1273
+ var tmp4_configPath = _this__u8e3s4.c5o_1;
1274
+ var tmp;
1275
+ switch (_this__u8e3s4.b5o_1.a5n_1.l5n_1.o2_1) {
1276
+ case 3:
1277
+ case 0:
1278
+ tmp = CredentialPolicy_AUTO_getInstance();
1279
+ break;
1280
+ case 1:
1281
+ tmp = CredentialPolicy_USER_SESSION_getInstance();
1282
+ break;
1283
+ case 2:
1284
+ tmp = CredentialPolicy_PAT_ENV_getInstance();
1285
+ break;
1286
+ default:
1287
+ noWhenBranchMatchedException();
1288
+ break;
1289
+ }
1290
+ var tmp5_credentialPolicy = tmp;
1291
+ // Inline function 'kotlin.collections.map' call
1292
+ var this_0 = _this__u8e3s4.b5o_1.d5n_1;
1293
+ // Inline function 'kotlin.collections.mapTo' call
1294
+ var destination = ArrayList_init_$Create$(collectionSizeOrDefault(this_0, 10));
1295
+ var _iterator__ex2g4s = this_0.l();
1296
+ while (_iterator__ex2g4s.m()) {
1297
+ var item = _iterator__ex2g4s.n();
1298
+ var tmp0_elvis_lhs = Companion_getInstance_0().o5p(item);
1299
+ var tmp_0;
1300
+ if (tmp0_elvis_lhs == null) {
1301
+ throw new UnknownTargetPlatformException(item, _this__u8e3s4.c5o_1);
1302
+ } else {
1303
+ tmp_0 = tmp0_elvis_lhs;
1304
+ }
1305
+ var tmp$ret$0 = tmp_0;
1306
+ destination.j(tmp$ret$0);
1307
+ }
1308
+ return new ProjectContext(tmp1_projectId, tmp2_designSystemId, tmp3_credentialEnvName, tmp4_configPath, destination, tmp5_credentialPolicy);
1309
+ }
1310
+ function UnknownTargetPlatformException(value, configPath) {
1311
+ IllegalArgumentException_init_$Init$("unknown platform '" + value + "' in " + configPath + '. Supported platforms: ' + joinToString(Companion_getInstance_0().n5p_1) + '.', this);
1312
+ captureStack(this, UnknownTargetPlatformException);
1313
+ }
1314
+ function projectDirectory($this, configPath) {
1315
+ var tmp0_elvis_lhs = $this.g5q_1.s5n($this.g5q_1.e5o(configPath));
1316
+ var tmp;
1317
+ if (tmp0_elvis_lhs == null) {
1318
+ throw new ProjectEnvironmentException('Invalid project config path.');
1319
+ } else {
1320
+ tmp = tmp0_elvis_lhs;
1321
+ }
1322
+ var configDirectory = tmp;
1323
+ var tmp1_elvis_lhs = $this.g5q_1.s5n(configDirectory);
1324
+ var tmp_0;
1325
+ if (tmp1_elvis_lhs == null) {
1326
+ throw new ProjectEnvironmentException('Invalid project config path.');
1327
+ } else {
1328
+ tmp_0 = tmp1_elvis_lhs;
1329
+ }
1330
+ return tmp_0;
1331
+ }
1332
+ function readContent($this, envPath) {
1333
+ var tmp;
1334
+ try {
1335
+ tmp = $this.g5q_1.h5o(envPath);
1336
+ } catch ($p) {
1337
+ var tmp_0;
1338
+ if ($p instanceof Exception) {
1339
+ var _unused_var__etf5q3 = $p;
1340
+ throw new ProjectEnvironmentException('Cannot read project .env at ' + envPath + '.');
1341
+ } else {
1342
+ throw $p;
1343
+ }
1344
+ }
1345
+ var bytes = tmp;
1346
+ var tmp_1;
1347
+ try {
1348
+ tmp_1 = decodeToString(bytes, VOID, VOID, true);
1349
+ } catch ($p) {
1350
+ var tmp_2;
1351
+ if ($p instanceof Exception) {
1352
+ var _unused_var__etf5q3_0 = $p;
1353
+ throw new ProjectEnvironmentException('Invalid UTF-8 in project .env at ' + envPath + '.');
1354
+ } else {
1355
+ throw $p;
1356
+ }
1357
+ }
1358
+ return tmp_1;
1359
+ }
1360
+ function sam$com_dsbuilder_frontend_core_auth_EnvironmentReader$0(function_0) {
1361
+ this.m5s_1 = function_0;
1362
+ }
1363
+ protoOf(sam$com_dsbuilder_frontend_core_auth_EnvironmentReader$0).xd = function (name) {
1364
+ return this.m5s_1(name);
1365
+ };
1366
+ protoOf(sam$com_dsbuilder_frontend_core_auth_EnvironmentReader$0).x2 = function () {
1367
+ return this.m5s_1;
1368
+ };
1369
+ protoOf(sam$com_dsbuilder_frontend_core_auth_EnvironmentReader$0).equals = function (other) {
1370
+ var tmp;
1371
+ if (!(other == null) ? isInterface(other, EnvironmentReader) : false) {
1372
+ var tmp_0;
1373
+ if (!(other == null) ? isInterface(other, FunctionAdapter) : false) {
1374
+ tmp_0 = equals(this.x2(), other.x2());
1375
+ } else {
1376
+ tmp_0 = false;
1377
+ }
1378
+ tmp = tmp_0;
1379
+ } else {
1380
+ tmp = false;
1381
+ }
1382
+ return tmp;
1383
+ };
1384
+ protoOf(sam$com_dsbuilder_frontend_core_auth_EnvironmentReader$0).hashCode = function () {
1385
+ return hashCode(this.x2());
1386
+ };
1387
+ function ProjectEnvironmentLoader$load$lambda($values) {
1388
+ return function (name) {
1389
+ return $values.c2(name);
1390
+ };
1391
+ }
1392
+ function ProjectEnvironmentLoader(fileSystem, parser) {
1393
+ parser = parser === VOID ? new ProjectEnvParser() : parser;
1394
+ this.g5q_1 = fileSystem;
1395
+ this.h5q_1 = parser;
1396
+ }
1397
+ protoOf(ProjectEnvironmentLoader).i5q = function (configPath) {
1398
+ var projectDirectory_0 = projectDirectory(this, configPath);
1399
+ var envPath = this.g5q_1.k4z(projectDirectory_0, '.env');
1400
+ if (!this.g5q_1.v4y(envPath))
1401
+ return null;
1402
+ var content = readContent(this, envPath);
1403
+ var tmp;
1404
+ try {
1405
+ tmp = this.h5q_1.tp(content);
1406
+ } catch ($p) {
1407
+ var tmp_0;
1408
+ if ($p instanceof ProjectEnvParseException) {
1409
+ var error = $p;
1410
+ throw new ProjectEnvironmentException('Invalid project .env at ' + envPath + ', line ' + error.d5o_1 + '.');
1411
+ } else {
1412
+ throw $p;
1413
+ }
1414
+ }
1415
+ var values = tmp;
1416
+ var tmp_1 = ProjectEnvironmentLoader$load$lambda(values);
1417
+ return new sam$com_dsbuilder_frontend_core_auth_EnvironmentReader$0(tmp_1);
1418
+ };
1419
+ function ProjectEnvironmentException(message) {
1420
+ IllegalArgumentException_init_$Init$(message, this);
1421
+ captureStack(this, ProjectEnvironmentException);
1422
+ }
1423
+ function RuntimeRequest(selection, apiUrlOverride, projectKeyOverride) {
1424
+ selection = selection === VOID ? new Local() : selection;
1425
+ apiUrlOverride = apiUrlOverride === VOID ? null : apiUrlOverride;
1426
+ projectKeyOverride = projectKeyOverride === VOID ? null : projectKeyOverride;
1427
+ this.n5s_1 = selection;
1428
+ this.o5s_1 = apiUrlOverride;
1429
+ this.p5s_1 = projectKeyOverride;
1430
+ }
1431
+ protoOf(RuntimeRequest).c9 = function () {
1432
+ var selected = this.n5s_1;
1433
+ var tmp;
1434
+ if (selected instanceof Local) {
1435
+ tmp = new ContextRequest(selected.r5s_1);
1436
+ } else {
1437
+ if (selected instanceof Link) {
1438
+ tmp = new ContextRequest(VOID, selected.q5s_1);
1439
+ } else {
1440
+ noWhenBranchMatchedException();
1441
+ }
1442
+ }
1443
+ return tmp;
1444
+ };
1445
+ protoOf(RuntimeRequest).toString = function () {
1446
+ return 'RuntimeRequest(selection=' + toString(this.n5s_1) + ', apiUrlOverride=' + this.o5s_1 + ', projectKeyOverride=' + this.p5s_1 + ')';
1447
+ };
1448
+ protoOf(RuntimeRequest).hashCode = function () {
1449
+ var result = hashCode(this.n5s_1);
1450
+ result = imul(result, 31) + (this.o5s_1 == null ? 0 : getStringHashCode(this.o5s_1)) | 0;
1451
+ result = imul(result, 31) + (this.p5s_1 == null ? 0 : getStringHashCode(this.p5s_1)) | 0;
1452
+ return result;
1453
+ };
1454
+ protoOf(RuntimeRequest).equals = function (other) {
1455
+ if (this === other)
1456
+ return true;
1457
+ if (!(other instanceof RuntimeRequest))
1458
+ return false;
1459
+ if (!equals(this.n5s_1, other.n5s_1))
1460
+ return false;
1461
+ if (!(this.o5s_1 == other.o5s_1))
1462
+ return false;
1463
+ if (!(this.p5s_1 == other.p5s_1))
1464
+ return false;
1465
+ return true;
1466
+ };
1467
+ function Local(startingDirectory) {
1468
+ startingDirectory = startingDirectory === VOID ? null : startingDirectory;
1469
+ this.r5s_1 = startingDirectory;
1470
+ }
1471
+ protoOf(Local).toString = function () {
1472
+ return 'Local(startingDirectory=' + this.r5s_1 + ')';
1473
+ };
1474
+ protoOf(Local).hashCode = function () {
1475
+ return this.r5s_1 == null ? 0 : getStringHashCode(this.r5s_1);
1476
+ };
1477
+ protoOf(Local).equals = function (other) {
1478
+ if (this === other)
1479
+ return true;
1480
+ if (!(other instanceof Local))
1481
+ return false;
1482
+ if (!(this.r5s_1 == other.r5s_1))
1483
+ return false;
1484
+ return true;
1485
+ };
1486
+ function Link(uri) {
1487
+ this.q5s_1 = uri;
1488
+ }
1489
+ protoOf(Link).toString = function () {
1490
+ return 'Link(uri=' + this.q5s_1 + ')';
1491
+ };
1492
+ protoOf(Link).hashCode = function () {
1493
+ return getStringHashCode(this.q5s_1);
1494
+ };
1495
+ protoOf(Link).equals = function (other) {
1496
+ if (this === other)
1497
+ return true;
1498
+ if (!(other instanceof Link))
1499
+ return false;
1500
+ if (!(this.q5s_1 === other.q5s_1))
1501
+ return false;
1502
+ return true;
1503
+ };
1504
+ function $resolveCOROUTINE$(_this__u8e3s4, apiUrl, projectKeyOverride, credentialEnvName, policy, resultContinuation) {
1505
+ CoroutineImpl.call(this, resultContinuation);
1506
+ this.a5t_1 = _this__u8e3s4;
1507
+ this.b5t_1 = apiUrl;
1508
+ this.c5t_1 = projectKeyOverride;
1509
+ this.d5t_1 = credentialEnvName;
1510
+ this.e5t_1 = policy;
1511
+ }
1512
+ protoOf($resolveCOROUTINE$).e9 = function () {
1513
+ var suspendResult = this.y8_1;
1514
+ $sm: do
1515
+ try {
1516
+ var tmp = this.w8_1;
1517
+ switch (tmp) {
1518
+ case 0:
1519
+ this.x8_1 = 3;
1520
+ if (this.e5t_1.equals(CredentialPolicy_AUTO_getInstance())) {
1521
+ this.w8_1 = 1;
1522
+ suspendResult = this.a5t_1.g5t(this.b5t_1, this.c5t_1, this.d5t_1, this);
1523
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
1524
+ return suspendResult;
1525
+ }
1526
+ continue $sm;
1527
+ } else {
1528
+ var tmp_0 = this;
1529
+ tmp_0.f5t_1 = new Failed_3(AuthErrorCode_AUTH_REQUIRED_getInstance(), 'Selected credential policy is not supported.');
1530
+ this.w8_1 = 2;
1531
+ continue $sm;
1532
+ }
1533
+
1534
+ case 1:
1535
+ this.f5t_1 = suspendResult;
1536
+ this.w8_1 = 2;
1537
+ continue $sm;
1538
+ case 2:
1539
+ return this.f5t_1;
1540
+ case 3:
1541
+ throw this.z8_1;
1542
+ }
1543
+ } catch ($p) {
1544
+ var e = $p;
1545
+ if (this.x8_1 === 3) {
1546
+ throw e;
1547
+ } else {
1548
+ this.w8_1 = this.x8_1;
1549
+ this.z8_1 = e;
1550
+ }
1551
+ }
1552
+ while (true);
1553
+ };
1554
+ function CredentialProvider() {
1555
+ }
1556
+ function ProjectContextReader() {
1557
+ }
1558
+ function ProjectApiUrlProvider() {
1559
+ }
1560
+ function Found_0(context, projectEnvironment) {
1561
+ projectEnvironment = projectEnvironment === VOID ? null : projectEnvironment;
1562
+ this.s5t_1 = context;
1563
+ this.t5t_1 = projectEnvironment;
1564
+ }
1565
+ protoOf(Found_0).toString = function () {
1566
+ return 'Found(context=' + this.s5t_1.toString() + ', projectEnvironment=' + toString_0(this.t5t_1) + ')';
1567
+ };
1568
+ protoOf(Found_0).hashCode = function () {
1569
+ var result = this.s5t_1.hashCode();
1570
+ result = imul(result, 31) + (this.t5t_1 == null ? 0 : hashCode(this.t5t_1)) | 0;
1571
+ return result;
1572
+ };
1573
+ protoOf(Found_0).equals = function (other) {
1574
+ if (this === other)
1575
+ return true;
1576
+ if (!(other instanceof Found_0))
1577
+ return false;
1578
+ if (!this.s5t_1.equals(other.s5t_1))
1579
+ return false;
1580
+ if (!equals(this.t5t_1, other.t5t_1))
1581
+ return false;
1582
+ return true;
1583
+ };
1584
+ function Failed_2(message, reason) {
1585
+ reason = reason === VOID ? ProjectContextFailure_INVALID_getInstance() : reason;
1586
+ this.u5t_1 = message;
1587
+ this.v5t_1 = reason;
1588
+ }
1589
+ protoOf(Failed_2).toString = function () {
1590
+ return 'Failed(message=' + this.u5t_1 + ', reason=' + this.v5t_1.toString() + ')';
1591
+ };
1592
+ protoOf(Failed_2).hashCode = function () {
1593
+ var result = getStringHashCode(this.u5t_1);
1594
+ result = imul(result, 31) + this.v5t_1.hashCode() | 0;
1595
+ return result;
1596
+ };
1597
+ protoOf(Failed_2).equals = function (other) {
1598
+ if (this === other)
1599
+ return true;
1600
+ if (!(other instanceof Failed_2))
1601
+ return false;
1602
+ if (!(this.u5t_1 === other.u5t_1))
1603
+ return false;
1604
+ if (!this.v5t_1.equals(other.v5t_1))
1605
+ return false;
1606
+ return true;
1607
+ };
1608
+ function Selected(credential, type) {
1609
+ this.w5t_1 = credential;
1610
+ this.x5t_1 = type;
1611
+ }
1612
+ protoOf(Selected).toString = function () {
1613
+ return 'Selected(credential=' + toString(this.w5t_1) + ', type=' + this.x5t_1.toString() + ')';
1614
+ };
1615
+ protoOf(Selected).hashCode = function () {
1616
+ var result = hashCode(this.w5t_1);
1617
+ result = imul(result, 31) + this.x5t_1.hashCode() | 0;
1618
+ return result;
1619
+ };
1620
+ protoOf(Selected).equals = function (other) {
1621
+ if (this === other)
1622
+ return true;
1623
+ if (!(other instanceof Selected))
1624
+ return false;
1625
+ if (!equals(this.w5t_1, other.w5t_1))
1626
+ return false;
1627
+ if (!this.x5t_1.equals(other.x5t_1))
1628
+ return false;
1629
+ return true;
1630
+ };
1631
+ function Failed_3(code, message) {
1632
+ this.y5t_1 = code;
1633
+ this.z5t_1 = message;
1634
+ }
1635
+ protoOf(Failed_3).toString = function () {
1636
+ return 'Failed(code=' + this.y5t_1.toString() + ', message=' + this.z5t_1 + ')';
1637
+ };
1638
+ protoOf(Failed_3).hashCode = function () {
1639
+ var result = this.y5t_1.hashCode();
1640
+ result = imul(result, 31) + getStringHashCode(this.z5t_1) | 0;
1641
+ return result;
1642
+ };
1643
+ protoOf(Failed_3).equals = function (other) {
1644
+ if (this === other)
1645
+ return true;
1646
+ if (!(other instanceof Failed_3))
1647
+ return false;
1648
+ if (!this.y5t_1.equals(other.y5t_1))
1649
+ return false;
1650
+ if (!(this.z5t_1 === other.z5t_1))
1651
+ return false;
1652
+ return true;
1653
+ };
1654
+ function CredentialRequest(apiUrl, projectKeyOverride, credentialEnvName, policy, projectEnvironment, forceRefresh, rejectedAccessToken) {
1655
+ projectKeyOverride = projectKeyOverride === VOID ? null : projectKeyOverride;
1656
+ projectEnvironment = projectEnvironment === VOID ? null : projectEnvironment;
1657
+ forceRefresh = forceRefresh === VOID ? false : forceRefresh;
1658
+ rejectedAccessToken = rejectedAccessToken === VOID ? null : rejectedAccessToken;
1659
+ this.i5t_1 = apiUrl;
1660
+ this.j5t_1 = projectKeyOverride;
1661
+ this.k5t_1 = credentialEnvName;
1662
+ this.l5t_1 = policy;
1663
+ this.m5t_1 = projectEnvironment;
1664
+ this.n5t_1 = forceRefresh;
1665
+ this.o5t_1 = rejectedAccessToken;
1666
+ }
1667
+ protoOf(CredentialRequest).toString = function () {
1668
+ return 'CredentialRequest(apiUrl=' + ProjectApiUrl__toString_impl_gcmdir(this.i5t_1) + ', projectKeyOverride=' + this.j5t_1 + ', credentialEnvName=' + CredentialEnvName__toString_impl_prwlz4(this.k5t_1) + ', policy=' + this.l5t_1.toString() + ', projectEnvironment=' + toString_0(this.m5t_1) + ', forceRefresh=' + this.n5t_1 + ', rejectedAccessToken=' + this.o5t_1 + ')';
1669
+ };
1670
+ protoOf(CredentialRequest).hashCode = function () {
1671
+ var result = ProjectApiUrl__hashCode_impl_5ejja4(this.i5t_1);
1672
+ result = imul(result, 31) + (this.j5t_1 == null ? 0 : getStringHashCode(this.j5t_1)) | 0;
1673
+ result = imul(result, 31) + CredentialEnvName__hashCode_impl_40qp69(this.k5t_1) | 0;
1674
+ result = imul(result, 31) + this.l5t_1.hashCode() | 0;
1675
+ result = imul(result, 31) + (this.m5t_1 == null ? 0 : hashCode(this.m5t_1)) | 0;
1676
+ result = imul(result, 31) + getBooleanHashCode(this.n5t_1) | 0;
1677
+ result = imul(result, 31) + (this.o5t_1 == null ? 0 : getStringHashCode(this.o5t_1)) | 0;
1678
+ return result;
1679
+ };
1680
+ protoOf(CredentialRequest).equals = function (other) {
1681
+ if (this === other)
1682
+ return true;
1683
+ if (!(other instanceof CredentialRequest))
1684
+ return false;
1685
+ if (!(this.i5t_1 === other.i5t_1))
1686
+ return false;
1687
+ if (!(this.j5t_1 == other.j5t_1))
1688
+ return false;
1689
+ if (!(this.k5t_1 === other.k5t_1))
1690
+ return false;
1691
+ if (!this.l5t_1.equals(other.l5t_1))
1692
+ return false;
1693
+ if (!equals(this.m5t_1, other.m5t_1))
1694
+ return false;
1695
+ if (!(this.n5t_1 === other.n5t_1))
1696
+ return false;
1697
+ if (!(this.o5t_1 == other.o5t_1))
1698
+ return false;
1699
+ return true;
1700
+ };
1701
+ var ProjectContextFailure_NOT_INITIALIZED_instance;
1702
+ var ProjectContextFailure_INVALID_CONTEXT_instance;
1703
+ var ProjectContextFailure_INVALID_instance;
1704
+ var ProjectContextFailure_entriesInitialized;
1705
+ function ProjectContextFailure_initEntries() {
1706
+ if (ProjectContextFailure_entriesInitialized)
1707
+ return Unit_instance;
1708
+ ProjectContextFailure_entriesInitialized = true;
1709
+ ProjectContextFailure_NOT_INITIALIZED_instance = new ProjectContextFailure('NOT_INITIALIZED', 0);
1710
+ ProjectContextFailure_INVALID_CONTEXT_instance = new ProjectContextFailure('INVALID_CONTEXT', 1);
1711
+ ProjectContextFailure_INVALID_instance = new ProjectContextFailure('INVALID', 2);
1712
+ }
1713
+ function ProjectContextFailure(name, ordinal) {
1714
+ Enum.call(this, name, ordinal);
1715
+ }
1716
+ function PersonalAccessTokenProvider() {
1717
+ }
1718
+ function ContextRequest(startingDirectory, designSystemUri) {
1719
+ startingDirectory = startingDirectory === VOID ? null : startingDirectory;
1720
+ designSystemUri = designSystemUri === VOID ? null : designSystemUri;
1721
+ this.k5q_1 = startingDirectory;
1722
+ this.l5q_1 = designSystemUri;
1723
+ }
1724
+ protoOf(ContextRequest).toString = function () {
1725
+ return 'ContextRequest(startingDirectory=' + this.k5q_1 + ', designSystemUri=' + this.l5q_1 + ')';
1726
+ };
1727
+ protoOf(ContextRequest).hashCode = function () {
1728
+ var result = this.k5q_1 == null ? 0 : getStringHashCode(this.k5q_1);
1729
+ result = imul(result, 31) + (this.l5q_1 == null ? 0 : getStringHashCode(this.l5q_1)) | 0;
1730
+ return result;
1731
+ };
1732
+ protoOf(ContextRequest).equals = function (other) {
1733
+ if (this === other)
1734
+ return true;
1735
+ if (!(other instanceof ContextRequest))
1736
+ return false;
1737
+ if (!(this.k5q_1 == other.k5q_1))
1738
+ return false;
1739
+ if (!(this.l5q_1 == other.l5q_1))
1740
+ return false;
1741
+ return true;
1742
+ };
1743
+ function ProjectContextFailure_NOT_INITIALIZED_getInstance() {
1744
+ ProjectContextFailure_initEntries();
1745
+ return ProjectContextFailure_NOT_INITIALIZED_instance;
1746
+ }
1747
+ function ProjectContextFailure_INVALID_CONTEXT_getInstance() {
1748
+ ProjectContextFailure_initEntries();
1749
+ return ProjectContextFailure_INVALID_CONTEXT_instance;
1750
+ }
1751
+ function ProjectContextFailure_INVALID_getInstance() {
1752
+ ProjectContextFailure_initEntries();
1753
+ return ProjectContextFailure_INVALID_instance;
1754
+ }
1755
+ function retryMultipart($this, send, $completion) {
1756
+ var tmp = new $retryMultipartCOROUTINE$($this, send, $completion);
1757
+ tmp.y8_1 = Unit_instance;
1758
+ tmp.z8_1 = null;
1759
+ return tmp.e9();
1760
+ }
1761
+ function retryResult($this, first, retry, $completion) {
1762
+ var tmp = new $retryResultCOROUTINE$($this, first, retry, $completion);
1763
+ tmp.y8_1 = Unit_instance;
1764
+ tmp.z8_1 = null;
1765
+ return tmp.e9();
1766
+ }
1767
+ function clearSession($this, $completion) {
1768
+ return $this.g5v_1.c5v_1.u54(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$clearSession$slambda_0($this.g5v_1, $this, null), $completion);
1769
+ }
1770
+ function refreshedClient($this, $completion) {
1771
+ var tmp = new $refreshedClientCOROUTINE$($this, $completion);
1772
+ tmp.y8_1 = Unit_instance;
1773
+ tmp.z8_1 = null;
1774
+ return tmp.e9();
1775
+ }
1776
+ function RefreshingAuthenticatedHttpClientFactory$RefreshingClient$get$slambda($path, resultContinuation) {
1777
+ this.y5v_1 = $path;
1778
+ CoroutineImpl.call(this, resultContinuation);
1779
+ }
1780
+ protoOf(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$get$slambda).a5w = function (it, $completion) {
1781
+ var tmp = this.b5w(it, $completion);
1782
+ tmp.y8_1 = Unit_instance;
1783
+ tmp.z8_1 = null;
1784
+ return tmp.e9();
1785
+ };
1786
+ protoOf(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$get$slambda).q9 = function (p1, $completion) {
1787
+ return this.a5w((!(p1 == null) ? isInterface(p1, AuthenticatedHttpClient) : false) ? p1 : THROW_CCE(), $completion);
1788
+ };
1789
+ protoOf(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$get$slambda).e9 = function () {
1790
+ var suspendResult = this.y8_1;
1791
+ $sm: do
1792
+ try {
1793
+ var tmp = this.w8_1;
1794
+ switch (tmp) {
1795
+ case 0:
1796
+ this.x8_1 = 2;
1797
+ this.w8_1 = 1;
1798
+ suspendResult = this.z5v_1.z59(this.y5v_1, this);
1799
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
1800
+ return suspendResult;
1801
+ }
1802
+
1803
+ continue $sm;
1804
+ case 1:
1805
+ return suspendResult;
1806
+ case 2:
1807
+ throw this.z8_1;
1808
+ }
1809
+ } catch ($p) {
1810
+ var e = $p;
1811
+ if (this.x8_1 === 2) {
1812
+ throw e;
1813
+ } else {
1814
+ this.w8_1 = this.x8_1;
1815
+ this.z8_1 = e;
1816
+ }
1817
+ }
1818
+ while (true);
1819
+ };
1820
+ protoOf(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$get$slambda).b5w = function (it, completion) {
1821
+ var i = new RefreshingAuthenticatedHttpClientFactory$RefreshingClient$get$slambda(this.y5v_1, completion);
1822
+ i.z5v_1 = it;
1823
+ return i;
1824
+ };
1825
+ function RefreshingAuthenticatedHttpClientFactory$RefreshingClient$get$slambda_0($path, resultContinuation) {
1826
+ var i = new RefreshingAuthenticatedHttpClientFactory$RefreshingClient$get$slambda($path, resultContinuation);
1827
+ var l = function (it, $completion) {
1828
+ return i.a5w(it, $completion);
1829
+ };
1830
+ l.$arity = 1;
1831
+ return l;
1832
+ }
1833
+ function RefreshingAuthenticatedHttpClientFactory$RefreshingClient$post$slambda($path, $body, resultContinuation) {
1834
+ this.k5w_1 = $path;
1835
+ this.l5w_1 = $body;
1836
+ CoroutineImpl.call(this, resultContinuation);
1837
+ }
1838
+ protoOf(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$post$slambda).a5w = function (it, $completion) {
1839
+ var tmp = this.b5w(it, $completion);
1840
+ tmp.y8_1 = Unit_instance;
1841
+ tmp.z8_1 = null;
1842
+ return tmp.e9();
1843
+ };
1844
+ protoOf(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$post$slambda).q9 = function (p1, $completion) {
1845
+ return this.a5w((!(p1 == null) ? isInterface(p1, AuthenticatedHttpClient) : false) ? p1 : THROW_CCE(), $completion);
1846
+ };
1847
+ protoOf(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$post$slambda).e9 = function () {
1848
+ var suspendResult = this.y8_1;
1849
+ $sm: do
1850
+ try {
1851
+ var tmp = this.w8_1;
1852
+ switch (tmp) {
1853
+ case 0:
1854
+ this.x8_1 = 2;
1855
+ this.w8_1 = 1;
1856
+ suspendResult = this.m5w_1.a5a(this.k5w_1, this.l5w_1, this);
1857
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
1858
+ return suspendResult;
1859
+ }
1860
+
1861
+ continue $sm;
1862
+ case 1:
1863
+ return suspendResult;
1864
+ case 2:
1865
+ throw this.z8_1;
1866
+ }
1867
+ } catch ($p) {
1868
+ var e = $p;
1869
+ if (this.x8_1 === 2) {
1870
+ throw e;
1871
+ } else {
1872
+ this.w8_1 = this.x8_1;
1873
+ this.z8_1 = e;
1874
+ }
1875
+ }
1876
+ while (true);
1877
+ };
1878
+ protoOf(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$post$slambda).b5w = function (it, completion) {
1879
+ var i = new RefreshingAuthenticatedHttpClientFactory$RefreshingClient$post$slambda(this.k5w_1, this.l5w_1, completion);
1880
+ i.m5w_1 = it;
1881
+ return i;
1882
+ };
1883
+ function RefreshingAuthenticatedHttpClientFactory$RefreshingClient$post$slambda_0($path, $body, resultContinuation) {
1884
+ var i = new RefreshingAuthenticatedHttpClientFactory$RefreshingClient$post$slambda($path, $body, resultContinuation);
1885
+ var l = function (it, $completion) {
1886
+ return i.a5w(it, $completion);
1887
+ };
1888
+ l.$arity = 1;
1889
+ return l;
1890
+ }
1891
+ function RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postJson$slambda($path, $body, resultContinuation) {
1892
+ this.v5w_1 = $path;
1893
+ this.w5w_1 = $body;
1894
+ CoroutineImpl.call(this, resultContinuation);
1895
+ }
1896
+ protoOf(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postJson$slambda).y5w = function (it, $completion) {
1897
+ var tmp = this.b5w(it, $completion);
1898
+ tmp.y8_1 = Unit_instance;
1899
+ tmp.z8_1 = null;
1900
+ return tmp.e9();
1901
+ };
1902
+ protoOf(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postJson$slambda).q9 = function (p1, $completion) {
1903
+ return this.y5w((!(p1 == null) ? isInterface(p1, AuthenticatedHttpClient) : false) ? p1 : THROW_CCE(), $completion);
1904
+ };
1905
+ protoOf(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postJson$slambda).e9 = function () {
1906
+ var suspendResult = this.y8_1;
1907
+ $sm: do
1908
+ try {
1909
+ var tmp = this.w8_1;
1910
+ switch (tmp) {
1911
+ case 0:
1912
+ this.x8_1 = 2;
1913
+ this.w8_1 = 1;
1914
+ suspendResult = this.x5w_1.c5a(this.v5w_1, this.w5w_1, this);
1915
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
1916
+ return suspendResult;
1917
+ }
1918
+
1919
+ continue $sm;
1920
+ case 1:
1921
+ return suspendResult;
1922
+ case 2:
1923
+ throw this.z8_1;
1924
+ }
1925
+ } catch ($p) {
1926
+ var e = $p;
1927
+ if (this.x8_1 === 2) {
1928
+ throw e;
1929
+ } else {
1930
+ this.w8_1 = this.x8_1;
1931
+ this.z8_1 = e;
1932
+ }
1933
+ }
1934
+ while (true);
1935
+ };
1936
+ protoOf(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postJson$slambda).b5w = function (it, completion) {
1937
+ var i = new RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postJson$slambda(this.v5w_1, this.w5w_1, completion);
1938
+ i.x5w_1 = it;
1939
+ return i;
1940
+ };
1941
+ function RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postJson$slambda_0($path, $body, resultContinuation) {
1942
+ var i = new RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postJson$slambda($path, $body, resultContinuation);
1943
+ var l = function (it, $completion) {
1944
+ return i.y5w(it, $completion);
1945
+ };
1946
+ l.$arity = 1;
1947
+ return l;
1948
+ }
1949
+ function RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postMultipart$slambda($path, $file, resultContinuation) {
1950
+ this.h5x_1 = $path;
1951
+ this.i5x_1 = $file;
1952
+ CoroutineImpl.call(this, resultContinuation);
1953
+ }
1954
+ protoOf(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postMultipart$slambda).y5w = function (it, $completion) {
1955
+ var tmp = this.b5w(it, $completion);
1956
+ tmp.y8_1 = Unit_instance;
1957
+ tmp.z8_1 = null;
1958
+ return tmp.e9();
1959
+ };
1960
+ protoOf(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postMultipart$slambda).q9 = function (p1, $completion) {
1961
+ return this.y5w((!(p1 == null) ? isInterface(p1, AuthenticatedHttpClient) : false) ? p1 : THROW_CCE(), $completion);
1962
+ };
1963
+ protoOf(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postMultipart$slambda).e9 = function () {
1964
+ var suspendResult = this.y8_1;
1965
+ $sm: do
1966
+ try {
1967
+ var tmp = this.w8_1;
1968
+ switch (tmp) {
1969
+ case 0:
1970
+ this.x8_1 = 2;
1971
+ this.w8_1 = 1;
1972
+ suspendResult = this.j5x_1.d5a(this.h5x_1, this.i5x_1, this);
1973
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
1974
+ return suspendResult;
1975
+ }
1976
+
1977
+ continue $sm;
1978
+ case 1:
1979
+ return suspendResult;
1980
+ case 2:
1981
+ throw this.z8_1;
1982
+ }
1983
+ } catch ($p) {
1984
+ var e = $p;
1985
+ if (this.x8_1 === 2) {
1986
+ throw e;
1987
+ } else {
1988
+ this.w8_1 = this.x8_1;
1989
+ this.z8_1 = e;
1990
+ }
1991
+ }
1992
+ while (true);
1993
+ };
1994
+ protoOf(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postMultipart$slambda).b5w = function (it, completion) {
1995
+ var i = new RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postMultipart$slambda(this.h5x_1, this.i5x_1, completion);
1996
+ i.j5x_1 = it;
1997
+ return i;
1998
+ };
1999
+ function RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postMultipart$slambda_0($path, $file, resultContinuation) {
2000
+ var i = new RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postMultipart$slambda($path, $file, resultContinuation);
2001
+ var l = function (it, $completion) {
2002
+ return i.y5w(it, $completion);
2003
+ };
2004
+ l.$arity = 1;
2005
+ return l;
2006
+ }
2007
+ function RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postMultipart$slambda_1($path, $files, resultContinuation) {
2008
+ this.s5x_1 = $path;
2009
+ this.t5x_1 = $files;
2010
+ CoroutineImpl.call(this, resultContinuation);
2011
+ }
2012
+ protoOf(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postMultipart$slambda_1).y5w = function (it, $completion) {
2013
+ var tmp = this.b5w(it, $completion);
2014
+ tmp.y8_1 = Unit_instance;
2015
+ tmp.z8_1 = null;
2016
+ return tmp.e9();
2017
+ };
2018
+ protoOf(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postMultipart$slambda_1).q9 = function (p1, $completion) {
2019
+ return this.y5w((!(p1 == null) ? isInterface(p1, AuthenticatedHttpClient) : false) ? p1 : THROW_CCE(), $completion);
2020
+ };
2021
+ protoOf(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postMultipart$slambda_1).e9 = function () {
2022
+ var suspendResult = this.y8_1;
2023
+ $sm: do
2024
+ try {
2025
+ var tmp = this.w8_1;
2026
+ switch (tmp) {
2027
+ case 0:
2028
+ this.x8_1 = 2;
2029
+ this.w8_1 = 1;
2030
+ suspendResult = this.u5x_1.e5a(this.s5x_1, this.t5x_1, this);
2031
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
2032
+ return suspendResult;
2033
+ }
2034
+
2035
+ continue $sm;
2036
+ case 1:
2037
+ return suspendResult;
2038
+ case 2:
2039
+ throw this.z8_1;
2040
+ }
2041
+ } catch ($p) {
2042
+ var e = $p;
2043
+ if (this.x8_1 === 2) {
2044
+ throw e;
2045
+ } else {
2046
+ this.w8_1 = this.x8_1;
2047
+ this.z8_1 = e;
2048
+ }
2049
+ }
2050
+ while (true);
2051
+ };
2052
+ protoOf(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postMultipart$slambda_1).b5w = function (it, completion) {
2053
+ var i = new RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postMultipart$slambda_1(this.s5x_1, this.t5x_1, completion);
2054
+ i.u5x_1 = it;
2055
+ return i;
2056
+ };
2057
+ function RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postMultipart$slambda_2($path, $files, resultContinuation) {
2058
+ var i = new RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postMultipart$slambda_1($path, $files, resultContinuation);
2059
+ var l = function (it, $completion) {
2060
+ return i.y5w(it, $completion);
2061
+ };
2062
+ l.$arity = 1;
2063
+ return l;
2064
+ }
2065
+ function RefreshingAuthenticatedHttpClientFactory$RefreshingClient$clearSession$slambda(this$0, this$1, resultContinuation) {
2066
+ this.d5y_1 = this$0;
2067
+ this.e5y_1 = this$1;
2068
+ CoroutineImpl.call(this, resultContinuation);
2069
+ }
2070
+ protoOf(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$clearSession$slambda).w1x = function ($completion) {
2071
+ var tmp = this.n4t($completion);
2072
+ tmp.y8_1 = Unit_instance;
2073
+ tmp.z8_1 = null;
2074
+ return tmp.e9();
2075
+ };
2076
+ protoOf(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$clearSession$slambda).na = function ($completion) {
2077
+ return this.w1x($completion);
2078
+ };
2079
+ protoOf(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$clearSession$slambda).e9 = function () {
2080
+ var suspendResult = this.y8_1;
2081
+ $sm: do
2082
+ try {
2083
+ var tmp = this.w8_1;
2084
+ switch (tmp) {
2085
+ case 0:
2086
+ this.x8_1 = 2;
2087
+ this.w8_1 = 1;
2088
+ suspendResult = this.d5y_1.b5v_1.x4x(this.e5y_1.d5v_1, this);
2089
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
2090
+ return suspendResult;
2091
+ }
2092
+
2093
+ continue $sm;
2094
+ case 1:
2095
+ this.d5y_1.c5v_1.x54(this.e5y_1.d5v_1);
2096
+ return Unit_instance;
2097
+ case 2:
2098
+ throw this.z8_1;
2099
+ }
2100
+ } catch ($p) {
2101
+ var e = $p;
2102
+ if (this.x8_1 === 2) {
2103
+ throw e;
2104
+ } else {
2105
+ this.w8_1 = this.x8_1;
2106
+ this.z8_1 = e;
2107
+ }
2108
+ }
2109
+ while (true);
2110
+ };
2111
+ protoOf(RefreshingAuthenticatedHttpClientFactory$RefreshingClient$clearSession$slambda).n4t = function (completion) {
2112
+ return new RefreshingAuthenticatedHttpClientFactory$RefreshingClient$clearSession$slambda(this.d5y_1, this.e5y_1, completion);
2113
+ };
2114
+ function RefreshingAuthenticatedHttpClientFactory$RefreshingClient$clearSession$slambda_0(this$0, this$1, resultContinuation) {
2115
+ var i = new RefreshingAuthenticatedHttpClientFactory$RefreshingClient$clearSession$slambda(this$0, this$1, resultContinuation);
2116
+ var l = function ($completion) {
2117
+ return i.w1x($completion);
2118
+ };
2119
+ l.$arity = 0;
2120
+ return l;
2121
+ }
2122
+ function $getCOROUTINE$(_this__u8e3s4, path, resultContinuation) {
2123
+ CoroutineImpl.call(this, resultContinuation);
2124
+ this.n5y_1 = _this__u8e3s4;
2125
+ this.o5y_1 = path;
2126
+ }
2127
+ protoOf($getCOROUTINE$).e9 = function () {
2128
+ var suspendResult = this.y8_1;
2129
+ $sm: do
2130
+ try {
2131
+ var tmp = this.w8_1;
2132
+ switch (tmp) {
2133
+ case 0:
2134
+ this.x8_1 = 3;
2135
+ this.w8_1 = 1;
2136
+ suspendResult = this.n5y_1.f5v_1.z59(this.o5y_1, this);
2137
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
2138
+ return suspendResult;
2139
+ }
2140
+
2141
+ continue $sm;
2142
+ case 1:
2143
+ var ARGUMENT = suspendResult;
2144
+ this.w8_1 = 2;
2145
+ suspendResult = retryResult(this.n5y_1, ARGUMENT, RefreshingAuthenticatedHttpClientFactory$RefreshingClient$get$slambda_0(this.o5y_1, null), this);
2146
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
2147
+ return suspendResult;
2148
+ }
2149
+
2150
+ continue $sm;
2151
+ case 2:
2152
+ return suspendResult;
2153
+ case 3:
2154
+ throw this.z8_1;
2155
+ }
2156
+ } catch ($p) {
2157
+ var e = $p;
2158
+ if (this.x8_1 === 3) {
2159
+ throw e;
2160
+ } else {
2161
+ this.w8_1 = this.x8_1;
2162
+ this.z8_1 = e;
2163
+ }
2164
+ }
2165
+ while (true);
2166
+ };
2167
+ function $postCOROUTINE$(_this__u8e3s4, path, body, resultContinuation) {
2168
+ CoroutineImpl.call(this, resultContinuation);
2169
+ this.x5y_1 = _this__u8e3s4;
2170
+ this.y5y_1 = path;
2171
+ this.z5y_1 = body;
2172
+ }
2173
+ protoOf($postCOROUTINE$).e9 = function () {
2174
+ var suspendResult = this.y8_1;
2175
+ $sm: do
2176
+ try {
2177
+ var tmp = this.w8_1;
2178
+ switch (tmp) {
2179
+ case 0:
2180
+ this.x8_1 = 3;
2181
+ this.w8_1 = 1;
2182
+ suspendResult = this.x5y_1.f5v_1.a5a(this.y5y_1, this.z5y_1, this);
2183
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
2184
+ return suspendResult;
2185
+ }
2186
+
2187
+ continue $sm;
2188
+ case 1:
2189
+ var ARGUMENT = suspendResult;
2190
+ this.w8_1 = 2;
2191
+ suspendResult = retryResult(this.x5y_1, ARGUMENT, RefreshingAuthenticatedHttpClientFactory$RefreshingClient$post$slambda_0(this.y5y_1, this.z5y_1, null), this);
2192
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
2193
+ return suspendResult;
2194
+ }
2195
+
2196
+ continue $sm;
2197
+ case 2:
2198
+ return suspendResult;
2199
+ case 3:
2200
+ throw this.z8_1;
2201
+ }
2202
+ } catch ($p) {
2203
+ var e = $p;
2204
+ if (this.x8_1 === 3) {
2205
+ throw e;
2206
+ } else {
2207
+ this.w8_1 = this.x8_1;
2208
+ this.z8_1 = e;
2209
+ }
2210
+ }
2211
+ while (true);
2212
+ };
2213
+ function $mutateCOROUTINE$(_this__u8e3s4, request, resultContinuation) {
2214
+ CoroutineImpl.call(this, resultContinuation);
2215
+ this.i5z_1 = _this__u8e3s4;
2216
+ this.j5z_1 = request;
2217
+ }
2218
+ protoOf($mutateCOROUTINE$).e9 = function () {
2219
+ var suspendResult = this.y8_1;
2220
+ $sm: do
2221
+ try {
2222
+ var tmp = this.w8_1;
2223
+ switch (tmp) {
2224
+ case 0:
2225
+ this.x8_1 = 7;
2226
+ this.w8_1 = 1;
2227
+ suspendResult = this.i5z_1.f5v_1.b5a(this.j5z_1, this);
2228
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
2229
+ return suspendResult;
2230
+ }
2231
+
2232
+ continue $sm;
2233
+ case 1:
2234
+ var first = suspendResult;
2235
+ var tmp_0;
2236
+ var tmp_1;
2237
+ if (!(first instanceof Response)) {
2238
+ tmp_1 = true;
2239
+ } else {
2240
+ tmp_1 = !(first.f5f_1 === 401);
2241
+ }
2242
+
2243
+ if (tmp_1) {
2244
+ tmp_0 = true;
2245
+ } else {
2246
+ var tmp_2 = this.i5z_1.e5v_1;
2247
+ tmp_0 = !(tmp_2 instanceof Bearer);
2248
+ }
2249
+
2250
+ if (tmp_0) {
2251
+ return first;
2252
+ }
2253
+
2254
+ this.w8_1 = 2;
2255
+ suspendResult = refreshedClient(this.i5z_1, this);
2256
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
2257
+ return suspendResult;
2258
+ }
2259
+
2260
+ continue $sm;
2261
+ case 2:
2262
+ var refreshed = suspendResult;
2263
+ if (refreshed instanceof Failed) {
2264
+ this.k5z_1 = new Response(errorStatus(this.i5z_1.g5v_1, refreshed.z4x_1), '', emptyMap(), true);
2265
+ this.w8_1 = 6;
2266
+ continue $sm;
2267
+ } else {
2268
+ if (refreshed instanceof Success) {
2269
+ this.w8_1 = 3;
2270
+ suspendResult = refreshed.y4x_1.b5a(this.j5z_1, this);
2271
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
2272
+ return suspendResult;
2273
+ }
2274
+ continue $sm;
2275
+ } else {
2276
+ var tmp_3 = this;
2277
+ noWhenBranchMatchedException();
2278
+ }
2279
+ }
2280
+
2281
+ break;
2282
+ case 3:
2283
+ this.l5z_1 = suspendResult;
2284
+ var second = this.l5z_1;
2285
+ var tmp_4;
2286
+ if (second instanceof Response) {
2287
+ tmp_4 = second.f5f_1 === 401;
2288
+ } else {
2289
+ tmp_4 = false;
2290
+ }
2291
+
2292
+ if (tmp_4) {
2293
+ this.w8_1 = 4;
2294
+ suspendResult = clearSession(this.i5z_1, this);
2295
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
2296
+ return suspendResult;
2297
+ }
2298
+ continue $sm;
2299
+ } else {
2300
+ this.w8_1 = 5;
2301
+ continue $sm;
2302
+ }
2303
+
2304
+ case 4:
2305
+ this.w8_1 = 5;
2306
+ continue $sm;
2307
+ case 5:
2308
+ this.k5z_1 = this.l5z_1;
2309
+ this.w8_1 = 6;
2310
+ continue $sm;
2311
+ case 6:
2312
+ return this.k5z_1;
2313
+ case 7:
2314
+ throw this.z8_1;
2315
+ }
2316
+ } catch ($p) {
2317
+ var e = $p;
2318
+ if (this.x8_1 === 7) {
2319
+ throw e;
2320
+ } else {
2321
+ this.w8_1 = this.x8_1;
2322
+ this.z8_1 = e;
2323
+ }
2324
+ }
2325
+ while (true);
2326
+ };
2327
+ function $retryMultipartCOROUTINE$(_this__u8e3s4, send, resultContinuation) {
2328
+ CoroutineImpl.call(this, resultContinuation);
2329
+ this.i5u_1 = _this__u8e3s4;
2330
+ this.j5u_1 = send;
2331
+ }
2332
+ protoOf($retryMultipartCOROUTINE$).e9 = function () {
2333
+ var suspendResult = this.y8_1;
2334
+ $sm: do
2335
+ try {
2336
+ var tmp = this.w8_1;
2337
+ switch (tmp) {
2338
+ case 0:
2339
+ this.x8_1 = 7;
2340
+ this.w8_1 = 1;
2341
+ suspendResult = this.j5u_1(this.i5u_1.f5v_1, this);
2342
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
2343
+ return suspendResult;
2344
+ }
2345
+
2346
+ continue $sm;
2347
+ case 1:
2348
+ var first = suspendResult;
2349
+ var tmp_0;
2350
+ if (!(first.k5a_1 === 401)) {
2351
+ tmp_0 = true;
2352
+ } else {
2353
+ var tmp_1 = this.i5u_1.e5v_1;
2354
+ tmp_0 = !(tmp_1 instanceof Bearer);
2355
+ }
2356
+
2357
+ if (tmp_0)
2358
+ return first;
2359
+ this.w8_1 = 2;
2360
+ suspendResult = refreshedClient(this.i5u_1, this);
2361
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
2362
+ return suspendResult;
2363
+ }
2364
+
2365
+ continue $sm;
2366
+ case 2:
2367
+ var refreshed = suspendResult;
2368
+ if (refreshed instanceof Failed) {
2369
+ this.k5u_1 = new AuthenticatedHttpResponse(errorStatus(this.i5u_1.g5v_1, refreshed.z4x_1), refreshed.a4y_1);
2370
+ this.w8_1 = 6;
2371
+ continue $sm;
2372
+ } else {
2373
+ if (refreshed instanceof Success) {
2374
+ this.w8_1 = 3;
2375
+ suspendResult = this.j5u_1(refreshed.y4x_1, this);
2376
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
2377
+ return suspendResult;
2378
+ }
2379
+ continue $sm;
2380
+ } else {
2381
+ var tmp_2 = this;
2382
+ noWhenBranchMatchedException();
2383
+ }
2384
+ }
2385
+
2386
+ break;
2387
+ case 3:
2388
+ this.l5u_1 = suspendResult;
2389
+ if (this.l5u_1.k5a_1 === 401) {
2390
+ this.w8_1 = 4;
2391
+ suspendResult = clearSession(this.i5u_1, this);
2392
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
2393
+ return suspendResult;
2394
+ }
2395
+ continue $sm;
2396
+ } else {
2397
+ this.w8_1 = 5;
2398
+ continue $sm;
2399
+ }
2400
+
2401
+ case 4:
2402
+ this.w8_1 = 5;
2403
+ continue $sm;
2404
+ case 5:
2405
+ this.k5u_1 = this.l5u_1;
2406
+ this.w8_1 = 6;
2407
+ continue $sm;
2408
+ case 6:
2409
+ return this.k5u_1;
2410
+ case 7:
2411
+ throw this.z8_1;
2412
+ }
2413
+ } catch ($p) {
2414
+ var e = $p;
2415
+ if (this.x8_1 === 7) {
2416
+ throw e;
2417
+ } else {
2418
+ this.w8_1 = this.x8_1;
2419
+ this.z8_1 = e;
2420
+ }
2421
+ }
2422
+ while (true);
2423
+ };
2424
+ function $retryResultCOROUTINE$(_this__u8e3s4, first, retry, resultContinuation) {
2425
+ CoroutineImpl.call(this, resultContinuation);
2426
+ this.u5u_1 = _this__u8e3s4;
2427
+ this.v5u_1 = first;
2428
+ this.w5u_1 = retry;
2429
+ }
2430
+ protoOf($retryResultCOROUTINE$).e9 = function () {
2431
+ var suspendResult = this.y8_1;
2432
+ $sm: do
2433
+ try {
2434
+ var tmp = this.w8_1;
2435
+ switch (tmp) {
2436
+ case 0:
2437
+ this.x8_1 = 6;
2438
+ var tmp_0;
2439
+ var tmp_1 = this.v5u_1;
2440
+ if (!(tmp_1 instanceof Failure)) {
2441
+ tmp_0 = true;
2442
+ } else {
2443
+ tmp_0 = !(this.v5u_1.j5a_1 === 401);
2444
+ }
2445
+
2446
+ if (tmp_0)
2447
+ return this.v5u_1;
2448
+ var tmp_2 = this.u5u_1.e5v_1;
2449
+ if (!(tmp_2 instanceof Bearer))
2450
+ return this.v5u_1;
2451
+ this.w8_1 = 1;
2452
+ suspendResult = refreshedClient(this.u5u_1, this);
2453
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
2454
+ return suspendResult;
2455
+ }
2456
+
2457
+ continue $sm;
2458
+ case 1:
2459
+ var refreshed = suspendResult;
2460
+ if (refreshed instanceof Failed) {
2461
+ this.x5u_1 = new Failure(refreshed.a4y_1, errorStatus(this.u5u_1.g5v_1, refreshed.z4x_1));
2462
+ this.w8_1 = 5;
2463
+ continue $sm;
2464
+ } else {
2465
+ if (refreshed instanceof Success) {
2466
+ this.w8_1 = 2;
2467
+ suspendResult = this.w5u_1(refreshed.y4x_1, this);
2468
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
2469
+ return suspendResult;
2470
+ }
2471
+ continue $sm;
2472
+ } else {
2473
+ var tmp_3 = this;
2474
+ noWhenBranchMatchedException();
2475
+ }
2476
+ }
2477
+
2478
+ break;
2479
+ case 2:
2480
+ this.y5u_1 = suspendResult;
2481
+ var second = this.y5u_1;
2482
+ var tmp_4;
2483
+ if (second instanceof Failure) {
2484
+ tmp_4 = second.j5a_1 === 401;
2485
+ } else {
2486
+ tmp_4 = false;
2487
+ }
2488
+
2489
+ if (tmp_4) {
2490
+ this.w8_1 = 3;
2491
+ suspendResult = clearSession(this.u5u_1, this);
2492
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
2493
+ return suspendResult;
2494
+ }
2495
+ continue $sm;
2496
+ } else {
2497
+ this.w8_1 = 4;
2498
+ continue $sm;
2499
+ }
2500
+
2501
+ case 3:
2502
+ this.w8_1 = 4;
2503
+ continue $sm;
2504
+ case 4:
2505
+ this.x5u_1 = this.y5u_1;
2506
+ this.w8_1 = 5;
2507
+ continue $sm;
2508
+ case 5:
2509
+ return this.x5u_1;
2510
+ case 6:
2511
+ throw this.z8_1;
2512
+ }
2513
+ } catch ($p) {
2514
+ var e = $p;
2515
+ if (this.x8_1 === 6) {
2516
+ throw e;
2517
+ } else {
2518
+ this.w8_1 = this.x8_1;
2519
+ this.z8_1 = e;
2520
+ }
2521
+ }
2522
+ while (true);
2523
+ };
2524
+ function $refreshedClientCOROUTINE$(_this__u8e3s4, resultContinuation) {
2525
+ CoroutineImpl.call(this, resultContinuation);
2526
+ this.p5v_1 = _this__u8e3s4;
2527
+ }
2528
+ protoOf($refreshedClientCOROUTINE$).e9 = function () {
2529
+ var suspendResult = this.y8_1;
2530
+ $sm: do
2531
+ try {
2532
+ var tmp = this.w8_1;
2533
+ switch (tmp) {
2534
+ case 0:
2535
+ this.x8_1 = 2;
2536
+ this.w8_1 = 1;
2537
+ var tmp_0 = _ProjectApiUrl___init__impl__tmjeh7(this.p5v_1.d5v_1);
2538
+ var tmp_1 = _CredentialEnvName___init__impl__w41seg('DSBUILDER_API_KEY');
2539
+ var tmp_2 = CredentialPolicy_USER_SESSION_getInstance();
2540
+ var tmp_3 = this.p5v_1.e5v_1;
2541
+ var tmp0_safe_receiver = tmp_3 instanceof Bearer ? tmp_3 : null;
2542
+ suspendResult = this.p5v_1.g5v_1.a5v_1.h5t(new CredentialRequest(tmp_0, VOID, tmp_1, tmp_2, VOID, true, tmp0_safe_receiver == null ? null : tmp0_safe_receiver.o4x_1), this);
2543
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
2544
+ return suspendResult;
2545
+ }
2546
+
2547
+ continue $sm;
2548
+ case 1:
2549
+ var result = suspendResult;
2550
+ var tmp_4;
2551
+ if (result instanceof Failed_3) {
2552
+ tmp_4 = new Failed(result.y5t_1, result.z5t_1);
2553
+ } else {
2554
+ if (result instanceof Selected) {
2555
+ tmp_4 = new Success(this.p5v_1.g5v_1.z5u_1.y59(this.p5v_1.d5v_1, result.w5t_1));
2556
+ } else {
2557
+ noWhenBranchMatchedException();
2558
+ }
2559
+ }
2560
+
2561
+ return tmp_4;
2562
+ case 2:
2563
+ throw this.z8_1;
2564
+ }
2565
+ } catch ($p) {
2566
+ var e = $p;
2567
+ if (this.x8_1 === 2) {
2568
+ throw e;
2569
+ } else {
2570
+ this.w8_1 = this.x8_1;
2571
+ this.z8_1 = e;
2572
+ }
2573
+ }
2574
+ while (true);
2575
+ };
2576
+ function RefreshingClient($outer, apiUrl, credential) {
2577
+ this.g5v_1 = $outer;
2578
+ this.d5v_1 = apiUrl;
2579
+ this.e5v_1 = credential;
2580
+ this.f5v_1 = this.g5v_1.z5u_1.y59(this.d5v_1, this.e5v_1);
2581
+ }
2582
+ protoOf(RefreshingClient).z59 = function (path, $completion) {
2583
+ var tmp = new $getCOROUTINE$(this, path, $completion);
2584
+ tmp.y8_1 = Unit_instance;
2585
+ tmp.z8_1 = null;
2586
+ return tmp.e9();
2587
+ };
2588
+ protoOf(RefreshingClient).a5a = function (path, body, $completion) {
2589
+ var tmp = new $postCOROUTINE$(this, path, body, $completion);
2590
+ tmp.y8_1 = Unit_instance;
2591
+ tmp.z8_1 = null;
2592
+ return tmp.e9();
2593
+ };
2594
+ protoOf(RefreshingClient).b5a = function (request, $completion) {
2595
+ var tmp = new $mutateCOROUTINE$(this, request, $completion);
2596
+ tmp.y8_1 = Unit_instance;
2597
+ tmp.z8_1 = null;
2598
+ return tmp.e9();
2599
+ };
2600
+ protoOf(RefreshingClient).c5a = function (path, body, $completion) {
2601
+ return retryMultipart(this, RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postJson$slambda_0(path, body, null), $completion);
2602
+ };
2603
+ protoOf(RefreshingClient).d5a = function (path, file, $completion) {
2604
+ return retryMultipart(this, RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postMultipart$slambda_0(path, file, null), $completion);
2605
+ };
2606
+ protoOf(RefreshingClient).e5a = function (path, files, $completion) {
2607
+ return retryMultipart(this, RefreshingAuthenticatedHttpClientFactory$RefreshingClient$postMultipart$slambda_2(path, files, null), $completion);
2608
+ };
2609
+ function errorStatus($this, code) {
2610
+ switch (code.o2_1) {
2611
+ case 0:
2612
+ case 1:
2613
+ return 401;
2614
+ case 2:
2615
+ return 403;
2616
+ default:
2617
+ return 503;
2618
+ }
2619
+ }
2620
+ function RefreshingAuthenticatedHttpClientFactory(delegate, credentialProvider, credentialStore, cache) {
2621
+ cache = cache === VOID ? new UserAccessTokenCache() : cache;
2622
+ this.z5u_1 = delegate;
2623
+ this.a5v_1 = credentialProvider;
2624
+ this.b5v_1 = credentialStore;
2625
+ this.c5v_1 = cache;
2626
+ }
2627
+ protoOf(RefreshingAuthenticatedHttpClientFactory).x59 = function (apiUrl, apiKey) {
2628
+ return this.y59(apiUrl, new PersonalAccessToken(apiKey));
2629
+ };
2630
+ protoOf(RefreshingAuthenticatedHttpClientFactory).y59 = function (apiUrl, credential) {
2631
+ return new RefreshingClient(this, apiUrl, credential);
2632
+ };
2633
+ function resolveProjectKeyOrSession($this, request, $completion) {
2634
+ var tmp = new $resolveProjectKeyOrSessionCOROUTINE$($this, request, $completion);
2635
+ tmp.y8_1 = Unit_instance;
2636
+ tmp.z8_1 = null;
2637
+ return tmp.e9();
2638
+ }
2639
+ function resolveServiceOrSession($this, request, $completion) {
2640
+ var tmp = new $resolveServiceOrSessionCOROUTINE$($this, request, $completion);
2641
+ tmp.y8_1 = Unit_instance;
2642
+ tmp.z8_1 = null;
2643
+ return tmp.e9();
2644
+ }
2645
+ function resolveProjectKey($this, projectKeyOverride, credentialEnvName, projectEnvironment) {
2646
+ var tmp;
2647
+ try {
2648
+ tmp = $this.k60_1.w51(projectKeyOverride, _CredentialEnvName___get_value__impl__breyj8(credentialEnvName), projectEnvironment);
2649
+ } catch ($p) {
2650
+ var tmp_0;
2651
+ if ($p instanceof MissingPatException) {
2652
+ var _unused_var__etf5q3 = $p;
2653
+ tmp_0 = null;
2654
+ } else {
2655
+ throw $p;
2656
+ }
2657
+ tmp = tmp_0;
2658
+ }
2659
+ return tmp;
2660
+ }
2661
+ function resolveSessionCredential($this, apiUrl, forceRefresh, rejectedAccessToken, $completion) {
2662
+ return $this.p60_1.u54(RuntimeCredentialProvider$resolveSessionCredential$slambda_0($this, apiUrl, rejectedAccessToken, forceRefresh, null), $completion);
2663
+ }
2664
+ function isCompatible($this, session, apiUrl) {
2665
+ return session.g4y_1 === apiUrl && session.f4y_1 === 2 && session.l4y_1 === 'dsbuilder-studio-plugin';
2666
+ }
2667
+ function refreshSession($this, apiUrl, session, $completion) {
2668
+ var tmp = new $refreshSessionCOROUTINE$($this, apiUrl, session, $completion);
2669
+ tmp.y8_1 = Unit_instance;
2670
+ tmp.z8_1 = null;
2671
+ return tmp.e9();
2672
+ }
2673
+ function toCredentialResult($this, _this__u8e3s4, apiUrl, session, $completion) {
2674
+ var tmp = new $toCredentialResultCOROUTINE$($this, _this__u8e3s4, apiUrl, session, $completion);
2675
+ tmp.y8_1 = Unit_instance;
2676
+ tmp.z8_1 = null;
2677
+ return tmp.e9();
2678
+ }
2679
+ function sam$com_dsbuilder_frontend_core_auth_EnvironmentReader$0_0(function_0) {
2680
+ this.r61_1 = function_0;
2681
+ }
2682
+ protoOf(sam$com_dsbuilder_frontend_core_auth_EnvironmentReader$0_0).xd = function (name) {
2683
+ return this.r61_1(name);
2684
+ };
2685
+ protoOf(sam$com_dsbuilder_frontend_core_auth_EnvironmentReader$0_0).x2 = function () {
2686
+ return this.r61_1;
2687
+ };
2688
+ protoOf(sam$com_dsbuilder_frontend_core_auth_EnvironmentReader$0_0).equals = function (other) {
2689
+ var tmp;
2690
+ if (!(other == null) ? isInterface(other, EnvironmentReader) : false) {
2691
+ var tmp_0;
2692
+ if (!(other == null) ? isInterface(other, FunctionAdapter) : false) {
2693
+ tmp_0 = equals(this.x2(), other.x2());
2694
+ } else {
2695
+ tmp_0 = false;
2696
+ }
2697
+ tmp = tmp_0;
2698
+ } else {
2699
+ tmp = false;
2700
+ }
2701
+ return tmp;
2702
+ };
2703
+ protoOf(sam$com_dsbuilder_frontend_core_auth_EnvironmentReader$0_0).hashCode = function () {
2704
+ return hashCode(this.x2());
2705
+ };
2706
+ function RuntimeCredentialProvider$_init_$lambda_fjvv11(it) {
2707
+ return null;
2708
+ }
2709
+ function systemNowMillis$ref() {
2710
+ var l = function () {
2711
+ return systemNowMillis();
2712
+ };
2713
+ l.callableName = 'systemNowMillis';
2714
+ return l;
2715
+ }
2716
+ function RuntimeCredentialProvider$resolveSessionCredential$slambda(this$0, $apiUrl, $rejectedAccessToken, $forceRefresh, resultContinuation) {
2717
+ this.a62_1 = this$0;
2718
+ this.b62_1 = $apiUrl;
2719
+ this.c62_1 = $rejectedAccessToken;
2720
+ this.d62_1 = $forceRefresh;
2721
+ CoroutineImpl.call(this, resultContinuation);
2722
+ }
2723
+ protoOf(RuntimeCredentialProvider$resolveSessionCredential$slambda).e62 = function ($completion) {
2724
+ var tmp = this.n4t($completion);
2725
+ tmp.y8_1 = Unit_instance;
2726
+ tmp.z8_1 = null;
2727
+ return tmp.e9();
2728
+ };
2729
+ protoOf(RuntimeCredentialProvider$resolveSessionCredential$slambda).na = function ($completion) {
2730
+ return this.e62($completion);
2731
+ };
2732
+ protoOf(RuntimeCredentialProvider$resolveSessionCredential$slambda).e9 = function () {
2733
+ var suspendResult = this.y8_1;
2734
+ $sm: do
2735
+ try {
2736
+ var tmp = this.w8_1;
2737
+ switch (tmp) {
2738
+ case 0:
2739
+ this.x8_1 = 3;
2740
+ this.w8_1 = 1;
2741
+ suspendResult = this.a62_1.l60_1.v4x(_ProjectApiUrl___get_value__impl__ub99up(this.b62_1), this);
2742
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
2743
+ return suspendResult;
2744
+ }
2745
+
2746
+ continue $sm;
2747
+ case 1:
2748
+ var session = suspendResult;
2749
+ if (session == null || !isCompatible(this.a62_1, session, _ProjectApiUrl___get_value__impl__ub99up(this.b62_1))) {
2750
+ this.a62_1.p60_1.x54(_ProjectApiUrl___get_value__impl__ub99up(this.b62_1));
2751
+ return new Failed_3(AuthErrorCode_AUTH_REQUIRED_getInstance(), 'Error: authentication is required. Run auth login for browser authentication.');
2752
+ }
2753
+
2754
+ var cached = this.a62_1.p60_1.v54(session, this.a62_1.o60_1());
2755
+ var refreshedByAnotherRequest = !(this.c62_1 == null) && !(cached == this.c62_1);
2756
+ if (!(cached == null) && (!this.d62_1 || refreshedByAnotherRequest)) {
2757
+ return new Selected(new Bearer(cached), BackendCredentialType_USER_SESSION_getInstance());
2758
+ }
2759
+
2760
+ this.w8_1 = 2;
2761
+ suspendResult = refreshSession(this.a62_1, this.b62_1, session, this);
2762
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
2763
+ return suspendResult;
2764
+ }
2765
+
2766
+ continue $sm;
2767
+ case 2:
2768
+ return suspendResult;
2769
+ case 3:
2770
+ throw this.z8_1;
2771
+ }
2772
+ } catch ($p) {
2773
+ var e = $p;
2774
+ if (this.x8_1 === 3) {
2775
+ throw e;
2776
+ } else {
2777
+ this.w8_1 = this.x8_1;
2778
+ this.z8_1 = e;
2779
+ }
2780
+ }
2781
+ while (true);
2782
+ };
2783
+ protoOf(RuntimeCredentialProvider$resolveSessionCredential$slambda).n4t = function (completion) {
2784
+ return new RuntimeCredentialProvider$resolveSessionCredential$slambda(this.a62_1, this.b62_1, this.c62_1, this.d62_1, completion);
2785
+ };
2786
+ function RuntimeCredentialProvider$resolveSessionCredential$slambda_0(this$0, $apiUrl, $rejectedAccessToken, $forceRefresh, resultContinuation) {
2787
+ var i = new RuntimeCredentialProvider$resolveSessionCredential$slambda(this$0, $apiUrl, $rejectedAccessToken, $forceRefresh, resultContinuation);
2788
+ var l = function ($completion) {
2789
+ return i.e62($completion);
2790
+ };
2791
+ l.$arity = 0;
2792
+ return l;
2793
+ }
2794
+ function RuntimeCredentialProvider$refreshSession$slambda($currentSession, this$0, $apiUrl, resultContinuation) {
2795
+ this.n62_1 = $currentSession;
2796
+ this.o62_1 = this$0;
2797
+ this.p62_1 = $apiUrl;
2798
+ CoroutineImpl.call(this, resultContinuation);
2799
+ }
2800
+ protoOf(RuntimeCredentialProvider$refreshSession$slambda).r62 = function (lockedSession, $completion) {
2801
+ var tmp = this.s62(lockedSession, $completion);
2802
+ tmp.y8_1 = Unit_instance;
2803
+ tmp.z8_1 = null;
2804
+ return tmp.e9();
2805
+ };
2806
+ protoOf(RuntimeCredentialProvider$refreshSession$slambda).q9 = function (p1, $completion) {
2807
+ return this.r62(p1 instanceof UserSession ? p1 : THROW_CCE(), $completion);
2808
+ };
2809
+ protoOf(RuntimeCredentialProvider$refreshSession$slambda).e9 = function () {
2810
+ var suspendResult = this.y8_1;
2811
+ $sm: do
2812
+ try {
2813
+ var tmp = this.w8_1;
2814
+ switch (tmp) {
2815
+ case 0:
2816
+ this.x8_1 = 2;
2817
+ this.n62_1._v = this.q62_1;
2818
+ this.w8_1 = 1;
2819
+ suspendResult = this.o62_1.m60_1.s4x(_ProjectApiUrl___get_value__impl__ub99up(this.p62_1), this.q62_1.i4y_1, this);
2820
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
2821
+ return suspendResult;
2822
+ }
2823
+
2824
+ continue $sm;
2825
+ case 1:
2826
+ return suspendResult;
2827
+ case 2:
2828
+ throw this.z8_1;
2829
+ }
2830
+ } catch ($p) {
2831
+ var e = $p;
2832
+ if (this.x8_1 === 2) {
2833
+ throw e;
2834
+ } else {
2835
+ this.w8_1 = this.x8_1;
2836
+ this.z8_1 = e;
2837
+ }
2838
+ }
2839
+ while (true);
2840
+ };
2841
+ protoOf(RuntimeCredentialProvider$refreshSession$slambda).s62 = function (lockedSession, completion) {
2842
+ var i = new RuntimeCredentialProvider$refreshSession$slambda(this.n62_1, this.o62_1, this.p62_1, completion);
2843
+ i.q62_1 = lockedSession;
2844
+ return i;
2845
+ };
2846
+ function RuntimeCredentialProvider$refreshSession$slambda_0($currentSession, this$0, $apiUrl, resultContinuation) {
2847
+ var i = new RuntimeCredentialProvider$refreshSession$slambda($currentSession, this$0, $apiUrl, resultContinuation);
2848
+ var l = function (lockedSession, $completion) {
2849
+ return i.r62(lockedSession, $completion);
2850
+ };
2851
+ l.$arity = 1;
2852
+ return l;
2853
+ }
2854
+ function $resolveCOROUTINE$_0(_this__u8e3s4, request, resultContinuation) {
2855
+ CoroutineImpl.call(this, resultContinuation);
2856
+ this.b63_1 = _this__u8e3s4;
2857
+ this.c63_1 = request;
2858
+ }
2859
+ protoOf($resolveCOROUTINE$_0).e9 = function () {
2860
+ var suspendResult = this.y8_1;
2861
+ $sm: do
2862
+ try {
2863
+ var tmp = this.w8_1;
2864
+ switch (tmp) {
2865
+ case 0:
2866
+ this.x8_1 = 5;
2867
+ var tmp0 = this.c63_1.l5t_1.o2_1;
2868
+ if (tmp0 === 1) {
2869
+ this.w8_1 = 3;
2870
+ suspendResult = resolveSessionCredential(this.b63_1, this.c63_1.i5t_1, this.c63_1.n5t_1, this.c63_1.o5t_1, this);
2871
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
2872
+ return suspendResult;
2873
+ }
2874
+ continue $sm;
2875
+ } else {
2876
+ if (tmp0 === 3) {
2877
+ this.w8_1 = 2;
2878
+ suspendResult = resolveServiceOrSession(this.b63_1, this.c63_1, this);
2879
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
2880
+ return suspendResult;
2881
+ }
2882
+ continue $sm;
2883
+ } else {
2884
+ switch (tmp0) {
2885
+ case 0:
2886
+ case 2:
2887
+ this.w8_1 = 1;
2888
+ suspendResult = resolveProjectKeyOrSession(this.b63_1, this.c63_1, this);
2889
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
2890
+ return suspendResult;
2891
+ }
2892
+
2893
+ continue $sm;
2894
+ default:
2895
+ var tmp_0 = this;
2896
+ noWhenBranchMatchedException();
2897
+ break;
2898
+ }
2899
+ }
2900
+ }
2901
+
2902
+ break;
2903
+ case 1:
2904
+ this.d63_1 = suspendResult;
2905
+ this.w8_1 = 4;
2906
+ continue $sm;
2907
+ case 2:
2908
+ this.d63_1 = suspendResult;
2909
+ this.w8_1 = 4;
2910
+ continue $sm;
2911
+ case 3:
2912
+ this.d63_1 = suspendResult;
2913
+ this.w8_1 = 4;
2914
+ continue $sm;
2915
+ case 4:
2916
+ return this.d63_1;
2917
+ case 5:
2918
+ throw this.z8_1;
2919
+ }
2920
+ } catch ($p) {
2921
+ var e = $p;
2922
+ if (this.x8_1 === 5) {
2923
+ throw e;
2924
+ } else {
2925
+ this.w8_1 = this.x8_1;
2926
+ this.z8_1 = e;
2927
+ }
2928
+ }
2929
+ while (true);
2930
+ };
2931
+ function $resolveProjectKeyOrSessionCOROUTINE$(_this__u8e3s4, request, resultContinuation) {
2932
+ CoroutineImpl.call(this, resultContinuation);
2933
+ this.u5z_1 = _this__u8e3s4;
2934
+ this.v5z_1 = request;
2935
+ }
2936
+ protoOf($resolveProjectKeyOrSessionCOROUTINE$).e9 = function () {
2937
+ var suspendResult = this.y8_1;
2938
+ $sm: do
2939
+ try {
2940
+ var tmp = this.w8_1;
2941
+ switch (tmp) {
2942
+ case 0:
2943
+ this.x8_1 = 3;
2944
+ var credentialEnvName = this.v5z_1.k5t_1;
2945
+ var key = resolveProjectKey(this.u5z_1, this.v5z_1.j5t_1, credentialEnvName, this.v5z_1.m5t_1);
2946
+ if (key == null && this.v5z_1.l5t_1.equals(CredentialPolicy_PAT_ENV_getInstance())) {
2947
+ return new Failed_3(AuthErrorCode_AUTH_REQUIRED_getInstance(), 'Error: PAT is required from ' + _CredentialEnvName___get_value__impl__breyj8(credentialEnvName) + '.');
2948
+ }
2949
+
2950
+ var tmp_0;
2951
+ if (key == null) {
2952
+ tmp_0 = null;
2953
+ } else {
2954
+ tmp_0 = new Selected(new PersonalAccessToken(key.x51_1), BackendCredentialType_PERSONAL_ACCESS_TOKEN_getInstance());
2955
+ }
2956
+
2957
+ var tmp1_elvis_lhs = tmp_0;
2958
+ if (tmp1_elvis_lhs == null) {
2959
+ this.w8_1 = 1;
2960
+ suspendResult = resolveSessionCredential(this.u5z_1, this.v5z_1.i5t_1, this.v5z_1.n5t_1, this.v5z_1.o5t_1, this);
2961
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
2962
+ return suspendResult;
2963
+ }
2964
+ continue $sm;
2965
+ } else {
2966
+ this.w5z_1 = tmp1_elvis_lhs;
2967
+ this.w8_1 = 2;
2968
+ continue $sm;
2969
+ }
2970
+
2971
+ case 1:
2972
+ this.w5z_1 = suspendResult;
2973
+ this.w8_1 = 2;
2974
+ continue $sm;
2975
+ case 2:
2976
+ return this.w5z_1;
2977
+ case 3:
2978
+ throw this.z8_1;
2979
+ }
2980
+ } catch ($p) {
2981
+ var e = $p;
2982
+ if (this.x8_1 === 3) {
2983
+ throw e;
2984
+ } else {
2985
+ this.w8_1 = this.x8_1;
2986
+ this.z8_1 = e;
2987
+ }
2988
+ }
2989
+ while (true);
2990
+ };
2991
+ function $resolveServiceOrSessionCOROUTINE$(_this__u8e3s4, request, resultContinuation) {
2992
+ CoroutineImpl.call(this, resultContinuation);
2993
+ this.f60_1 = _this__u8e3s4;
2994
+ this.g60_1 = request;
2995
+ }
2996
+ protoOf($resolveServiceOrSessionCOROUTINE$).e9 = function () {
2997
+ var suspendResult = this.y8_1;
2998
+ $sm: do
2999
+ try {
3000
+ var tmp = this.w8_1;
3001
+ switch (tmp) {
3002
+ case 0:
3003
+ this.x8_1 = 4;
3004
+ this.j60_1 = this.g60_1.i5t_1;
3005
+ var tmp_0 = this;
3006
+ var tmp0_safe_receiver = this.f60_1.n60_1.xd('DSBUILDER_CLIENT_ID');
3007
+ var tmp_1;
3008
+ if (tmp0_safe_receiver == null) {
3009
+ tmp_1 = null;
3010
+ } else {
3011
+ var tmp_2;
3012
+ if (!isBlank(tmp0_safe_receiver)) {
3013
+ tmp_2 = tmp0_safe_receiver;
3014
+ } else {
3015
+ tmp_2 = null;
3016
+ }
3017
+ tmp_1 = tmp_2;
3018
+ }
3019
+
3020
+ tmp_0.i60_1 = tmp_1;
3021
+ var tmp_3 = this;
3022
+ var tmp1_safe_receiver = this.f60_1.n60_1.xd('DSBUILDER_CLIENT_SECRET');
3023
+ var tmp_4;
3024
+ if (tmp1_safe_receiver == null) {
3025
+ tmp_4 = null;
3026
+ } else {
3027
+ var tmp_5;
3028
+ if (!isBlank(tmp1_safe_receiver)) {
3029
+ tmp_5 = tmp1_safe_receiver;
3030
+ } else {
3031
+ tmp_5 = null;
3032
+ }
3033
+ tmp_4 = tmp_5;
3034
+ }
3035
+
3036
+ tmp_3.h60_1 = tmp_4;
3037
+ if (this.i60_1 == null && this.h60_1 == null) {
3038
+ this.w8_1 = 3;
3039
+ suspendResult = resolveSessionCredential(this.f60_1, this.j60_1, this.g60_1.n5t_1, this.g60_1.o5t_1, this);
3040
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
3041
+ return suspendResult;
3042
+ }
3043
+ continue $sm;
3044
+ } else {
3045
+ this.w8_1 = 1;
3046
+ continue $sm;
3047
+ }
3048
+
3049
+ case 1:
3050
+ if (this.i60_1 == null || this.h60_1 == null) {
3051
+ return new Failed_3(AuthErrorCode_AUTH_REQUIRED_getInstance(), 'Error: set both DSBUILDER_CLIENT_ID and DSBUILDER_CLIENT_SECRET to sign in as a service account.');
3052
+ }
3053
+
3054
+ this.w8_1 = 2;
3055
+ suspendResult = this.f60_1.m60_1.u4x(_ProjectApiUrl___get_value__impl__ub99up(this.j60_1), this.i60_1, this.h60_1, this);
3056
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
3057
+ return suspendResult;
3058
+ }
3059
+
3060
+ continue $sm;
3061
+ case 2:
3062
+ var token = suspendResult;
3063
+ var tmp_6;
3064
+ if (token instanceof Failed) {
3065
+ tmp_6 = new Failed_3(token.z4x_1, token.a4y_1);
3066
+ } else {
3067
+ if (token instanceof Success) {
3068
+ tmp_6 = new Selected(new ServiceToken(token.y4x_1.q4y_1), BackendCredentialType_SERVICE_ACCOUNT_getInstance());
3069
+ } else {
3070
+ noWhenBranchMatchedException();
3071
+ }
3072
+ }
3073
+
3074
+ return tmp_6;
3075
+ case 3:
3076
+ return suspendResult;
3077
+ case 4:
3078
+ throw this.z8_1;
3079
+ }
3080
+ } catch ($p) {
3081
+ var e = $p;
3082
+ if (this.x8_1 === 4) {
3083
+ throw e;
3084
+ } else {
3085
+ this.w8_1 = this.x8_1;
3086
+ this.z8_1 = e;
3087
+ }
3088
+ }
3089
+ while (true);
3090
+ };
3091
+ function $refreshSessionCOROUTINE$(_this__u8e3s4, apiUrl, session, resultContinuation) {
3092
+ CoroutineImpl.call(this, resultContinuation);
3093
+ this.y60_1 = _this__u8e3s4;
3094
+ this.z60_1 = apiUrl;
3095
+ this.a61_1 = session;
3096
+ }
3097
+ protoOf($refreshSessionCOROUTINE$).e9 = function () {
3098
+ var suspendResult = this.y8_1;
3099
+ $sm: do
3100
+ try {
3101
+ var tmp = this.w8_1;
3102
+ switch (tmp) {
3103
+ case 0:
3104
+ this.x8_1 = 7;
3105
+ this.b61_1 = {_v: this.a61_1};
3106
+ var tmp_0 = this.y60_1.l60_1;
3107
+ if (isInterface(tmp_0, RotatingCredentialStore)) {
3108
+ this.w8_1 = 4;
3109
+ var tmp_1 = _ProjectApiUrl___get_value__impl__ub99up(this.z60_1);
3110
+ suspendResult = this.y60_1.l60_1.p4y(tmp_1, RuntimeCredentialProvider$refreshSession$slambda_0(this.b61_1, this.y60_1, this.z60_1, null), this);
3111
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
3112
+ return suspendResult;
3113
+ }
3114
+ continue $sm;
3115
+ } else {
3116
+ this.w8_1 = 1;
3117
+ suspendResult = this.y60_1.m60_1.s4x(_ProjectApiUrl___get_value__impl__ub99up(this.z60_1), this.a61_1.i4y_1, this);
3118
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
3119
+ return suspendResult;
3120
+ }
3121
+ continue $sm;
3122
+ }
3123
+
3124
+ case 1:
3125
+ this.d61_1 = suspendResult;
3126
+ var result = this.d61_1;
3127
+ if (result instanceof Success) {
3128
+ this.w8_1 = 2;
3129
+ suspendResult = this.y60_1.l60_1.w4x(this.a61_1.n4y(VOID, VOID, VOID, result.y4x_1.c4y_1, result.y4x_1.d4y_1), this);
3130
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
3131
+ return suspendResult;
3132
+ }
3133
+ continue $sm;
3134
+ } else {
3135
+ this.w8_1 = 3;
3136
+ continue $sm;
3137
+ }
3138
+
3139
+ case 2:
3140
+ this.w8_1 = 3;
3141
+ continue $sm;
3142
+ case 3:
3143
+ this.c61_1 = this.d61_1;
3144
+ this.w8_1 = 5;
3145
+ continue $sm;
3146
+ case 4:
3147
+ this.c61_1 = suspendResult;
3148
+ this.w8_1 = 5;
3149
+ continue $sm;
3150
+ case 5:
3151
+ var refreshed = this.c61_1;
3152
+ this.w8_1 = 6;
3153
+ suspendResult = toCredentialResult(this.y60_1, refreshed, this.z60_1, this.b61_1._v, this);
3154
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
3155
+ return suspendResult;
3156
+ }
3157
+
3158
+ continue $sm;
3159
+ case 6:
3160
+ return suspendResult;
3161
+ case 7:
3162
+ throw this.z8_1;
3163
+ }
3164
+ } catch ($p) {
3165
+ var e = $p;
3166
+ if (this.x8_1 === 7) {
3167
+ throw e;
3168
+ } else {
3169
+ this.w8_1 = this.x8_1;
3170
+ this.z8_1 = e;
3171
+ }
3172
+ }
3173
+ while (true);
3174
+ };
3175
+ function $toCredentialResultCOROUTINE$(_this__u8e3s4, _this__u8e3s4_0, apiUrl, session, resultContinuation) {
3176
+ CoroutineImpl.call(this, resultContinuation);
3177
+ this.m61_1 = _this__u8e3s4;
3178
+ this.n61_1 = _this__u8e3s4_0;
3179
+ this.o61_1 = apiUrl;
3180
+ this.p61_1 = session;
3181
+ }
3182
+ protoOf($toCredentialResultCOROUTINE$).e9 = function () {
3183
+ var suspendResult = this.y8_1;
3184
+ $sm: do
3185
+ try {
3186
+ var tmp = this.w8_1;
3187
+ switch (tmp) {
3188
+ case 0:
3189
+ this.x8_1 = 4;
3190
+ var tmp0_subject = this.n61_1;
3191
+ if (tmp0_subject instanceof Failed) {
3192
+ var tmp_0;
3193
+ if (this.n61_1.z4x_1.equals(AuthErrorCode_AUTH_REQUIRED_getInstance())) {
3194
+ var tmp_1 = this.m61_1.l60_1;
3195
+ tmp_0 = !isInterface(tmp_1, RotatingCredentialStore);
3196
+ } else {
3197
+ tmp_0 = false;
3198
+ }
3199
+ if (tmp_0) {
3200
+ this.w8_1 = 1;
3201
+ suspendResult = this.m61_1.l60_1.x4x(_ProjectApiUrl___get_value__impl__ub99up(this.o61_1), this);
3202
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
3203
+ return suspendResult;
3204
+ }
3205
+ continue $sm;
3206
+ } else {
3207
+ this.w8_1 = 2;
3208
+ continue $sm;
3209
+ }
3210
+ } else {
3211
+ if (tmp0_subject instanceof Success) {
3212
+ var tmp_2 = this;
3213
+ this.m61_1.p60_1.w54(this.p61_1, this.n61_1.y4x_1, this.m61_1.o60_1());
3214
+ tmp_2.q61_1 = new Selected(new Bearer(this.n61_1.y4x_1.b4y_1), BackendCredentialType_USER_SESSION_getInstance());
3215
+ this.w8_1 = 3;
3216
+ continue $sm;
3217
+ } else {
3218
+ var tmp_3 = this;
3219
+ noWhenBranchMatchedException();
3220
+ }
3221
+ }
3222
+
3223
+ break;
3224
+ case 1:
3225
+ this.w8_1 = 2;
3226
+ continue $sm;
3227
+ case 2:
3228
+ this.m61_1.p60_1.x54(_ProjectApiUrl___get_value__impl__ub99up(this.o61_1));
3229
+ this.q61_1 = new Failed_3(this.n61_1.z4x_1, this.n61_1.a4y_1);
3230
+ this.w8_1 = 3;
3231
+ continue $sm;
3232
+ case 3:
3233
+ return this.q61_1;
3234
+ case 4:
3235
+ throw this.z8_1;
3236
+ }
3237
+ } catch ($p) {
3238
+ var e = $p;
3239
+ if (this.x8_1 === 4) {
3240
+ throw e;
3241
+ } else {
3242
+ this.w8_1 = this.x8_1;
3243
+ this.z8_1 = e;
3244
+ }
3245
+ }
3246
+ while (true);
3247
+ };
3248
+ function RuntimeCredentialProvider(apiKeyResolver, credentialStore, tokenClient, environment, nowMillis, cache) {
3249
+ var tmp;
3250
+ if (environment === VOID) {
3251
+ var tmp_0 = RuntimeCredentialProvider$_init_$lambda_fjvv11;
3252
+ tmp = new sam$com_dsbuilder_frontend_core_auth_EnvironmentReader$0_0(tmp_0);
3253
+ } else {
3254
+ tmp = environment;
3255
+ }
3256
+ environment = tmp;
3257
+ var tmp_1;
3258
+ if (nowMillis === VOID) {
3259
+ tmp_1 = systemNowMillis$ref();
3260
+ } else {
3261
+ tmp_1 = nowMillis;
3262
+ }
3263
+ nowMillis = tmp_1;
3264
+ cache = cache === VOID ? new UserAccessTokenCache() : cache;
3265
+ this.k60_1 = apiKeyResolver;
3266
+ this.l60_1 = credentialStore;
3267
+ this.m60_1 = tokenClient;
3268
+ this.n60_1 = environment;
3269
+ this.o60_1 = nowMillis;
3270
+ this.p60_1 = cache;
3271
+ }
3272
+ protoOf(RuntimeCredentialProvider).g5t = function (apiUrl, projectKeyOverride, credentialEnvName, $completion) {
3273
+ return this.h5t(new CredentialRequest(apiUrl, projectKeyOverride, credentialEnvName, CredentialPolicy_AUTO_getInstance()), $completion);
3274
+ };
3275
+ protoOf(RuntimeCredentialProvider).p5t = function (apiUrl, projectKeyOverride, credentialEnvName, policy, $completion) {
3276
+ return this.h5t(new CredentialRequest(apiUrl, projectKeyOverride, credentialEnvName, policy), $completion);
3277
+ };
3278
+ protoOf(RuntimeCredentialProvider).h5t = function (request, $completion) {
3279
+ var tmp = new $resolveCOROUTINE$_0(this, request, $completion);
3280
+ tmp.y8_1 = Unit_instance;
3281
+ tmp.z8_1 = null;
3282
+ return tmp.e9();
3283
+ };
3284
+ function systemNowMillis() {
3285
+ return System_instance.zn().io();
3286
+ }
3287
+ function RuntimePersonalAccessTokenProvider(apiKeyResolver) {
3288
+ this.e63_1 = apiKeyResolver;
3289
+ }
3290
+ function RuntimeProjectApiUrlProvider(apiUrlResolver) {
3291
+ this.f63_1 = apiUrlResolver;
3292
+ }
3293
+ protoOf(RuntimeProjectApiUrlProvider).q5t = function (override) {
3294
+ return _ProjectApiUrl___init__impl__tmjeh7(this.f63_1.s59(override).m59_1);
3295
+ };
3296
+ protoOf(RuntimeProjectApiUrlProvider).r5t = function (override, projectEnvironment) {
3297
+ return _ProjectApiUrl___init__impl__tmjeh7(this.f63_1.r59(override, projectEnvironment).m59_1);
3298
+ };
3299
+ function $resolveCOROUTINE$_1(_this__u8e3s4, request, resultContinuation) {
3300
+ CoroutineImpl.call(this, resultContinuation);
3301
+ this.o63_1 = _this__u8e3s4;
3302
+ this.p63_1 = request;
3303
+ }
3304
+ protoOf($resolveCOROUTINE$_1).e9 = function () {
3305
+ var suspendResult = this.y8_1;
3306
+ $sm: do
3307
+ try {
3308
+ var tmp = this.w8_1;
3309
+ switch (tmp) {
3310
+ case 0:
3311
+ this.x8_1 = 2;
3312
+ var result = this.o63_1.x5r_1.j5q(this.p63_1.c9());
3313
+ var tmp_0;
3314
+ if (result instanceof Failed_2) {
3315
+ var tmp_1;
3316
+ switch (result.v5t_1.o2_1) {
3317
+ case 0:
3318
+ tmp_1 = RuntimeFailureCode_CONTEXT_REQUIRED_getInstance();
3319
+ break;
3320
+ case 1:
3321
+ tmp_1 = RuntimeFailureCode_INVALID_CONTEXT_getInstance();
3322
+ break;
3323
+ case 2:
3324
+ tmp_1 = RuntimeFailureCode_CONTEXT_NOT_FOUND_getInstance();
3325
+ break;
3326
+ default:
3327
+ noWhenBranchMatchedException();
3328
+ break;
3329
+ }
3330
+ return new Failed_4(tmp_1, result.u5t_1);
3331
+ } else {
3332
+ if (result instanceof Found_0) {
3333
+ tmp_0 = result;
3334
+ } else {
3335
+ noWhenBranchMatchedException();
3336
+ }
3337
+ }
3338
+
3339
+ var found = tmp_0;
3340
+ this.r63_1 = found.s5t_1;
3341
+ this.q63_1 = _ProjectApiUrl___init__impl__tmjeh7(this.o63_1.y5r_1.r59(this.p63_1.o5s_1, found.t5t_1).m59_1);
3342
+ this.w8_1 = 1;
3343
+ suspendResult = this.o63_1.z5r_1.h5t(new CredentialRequest(this.q63_1, this.p63_1.p5s_1, this.r63_1.z5o_1, this.r63_1.c5p_1, found.t5t_1), this);
3344
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
3345
+ return suspendResult;
3346
+ }
3347
+
3348
+ continue $sm;
3349
+ case 1:
3350
+ var credential = suspendResult;
3351
+ var tmp_2;
3352
+ if (credential instanceof Failed_3) {
3353
+ var tmp_3;
3354
+ switch (credential.y5t_1.o2_1) {
3355
+ case 0:
3356
+ tmp_3 = RuntimeFailureCode_AUTH_REQUIRED_getInstance();
3357
+ break;
3358
+ case 1:
3359
+ tmp_3 = RuntimeFailureCode_PAT_INVALID_getInstance();
3360
+ break;
3361
+ case 2:
3362
+ tmp_3 = RuntimeFailureCode_FORBIDDEN_getInstance();
3363
+ break;
3364
+ case 3:
3365
+ tmp_3 = RuntimeFailureCode_BACKEND_UNAVAILABLE_getInstance();
3366
+ break;
3367
+ case 4:
3368
+ tmp_3 = RuntimeFailureCode_INVALID_AUTH_URL_getInstance();
3369
+ break;
3370
+ default:
3371
+ noWhenBranchMatchedException();
3372
+ break;
3373
+ }
3374
+ tmp_2 = new Failed_4(tmp_3, credential.z5t_1);
3375
+ } else {
3376
+ if (credential instanceof Selected) {
3377
+ tmp_2 = new Resolved(this.r63_1, this.q63_1, credential.w5t_1);
3378
+ } else {
3379
+ noWhenBranchMatchedException();
3380
+ }
3381
+ }
3382
+
3383
+ return tmp_2;
3384
+ case 2:
3385
+ throw this.z8_1;
3386
+ }
3387
+ } catch ($p) {
3388
+ var e = $p;
3389
+ if (this.x8_1 === 2) {
3390
+ throw e;
3391
+ } else {
3392
+ this.w8_1 = this.x8_1;
3393
+ this.z8_1 = e;
3394
+ }
3395
+ }
3396
+ while (true);
3397
+ };
3398
+ function RuntimeRequestResolver(contextResolver, apiUrlResolver, credentialProvider) {
3399
+ this.x5r_1 = contextResolver;
3400
+ this.y5r_1 = apiUrlResolver;
3401
+ this.z5r_1 = credentialProvider;
3402
+ }
3403
+ protoOf(RuntimeRequestResolver).a5s = function (request, $completion) {
3404
+ var tmp = new $resolveCOROUTINE$_1(this, request, $completion);
3405
+ tmp.y8_1 = Unit_instance;
3406
+ tmp.z8_1 = null;
3407
+ return tmp.e9();
3408
+ };
3409
+ function Resolved(context, apiUrl, credential) {
3410
+ this.b5s_1 = context;
3411
+ this.c5s_1 = apiUrl;
3412
+ this.d5s_1 = credential;
3413
+ }
3414
+ protoOf(Resolved).toString = function () {
3415
+ return 'Resolved(context=' + this.b5s_1.toString() + ', apiUrl=' + ProjectApiUrl__toString_impl_gcmdir(this.c5s_1) + ', credential=' + toString(this.d5s_1) + ')';
3416
+ };
3417
+ protoOf(Resolved).hashCode = function () {
3418
+ var result = this.b5s_1.hashCode();
3419
+ result = imul(result, 31) + ProjectApiUrl__hashCode_impl_5ejja4(this.c5s_1) | 0;
3420
+ result = imul(result, 31) + hashCode(this.d5s_1) | 0;
3421
+ return result;
3422
+ };
3423
+ protoOf(Resolved).equals = function (other) {
3424
+ if (this === other)
3425
+ return true;
3426
+ if (!(other instanceof Resolved))
3427
+ return false;
3428
+ if (!this.b5s_1.equals(other.b5s_1))
3429
+ return false;
3430
+ if (!(this.c5s_1 === other.c5s_1))
3431
+ return false;
3432
+ if (!equals(this.d5s_1, other.d5s_1))
3433
+ return false;
3434
+ return true;
3435
+ };
3436
+ function Failed_4(code, message) {
3437
+ this.e5s_1 = code;
3438
+ this.f5s_1 = message;
3439
+ }
3440
+ protoOf(Failed_4).toString = function () {
3441
+ return 'Failed(code=' + this.e5s_1.toString() + ', message=' + this.f5s_1 + ')';
3442
+ };
3443
+ protoOf(Failed_4).hashCode = function () {
3444
+ var result = this.e5s_1.hashCode();
3445
+ result = imul(result, 31) + getStringHashCode(this.f5s_1) | 0;
3446
+ return result;
3447
+ };
3448
+ protoOf(Failed_4).equals = function (other) {
3449
+ if (this === other)
3450
+ return true;
3451
+ if (!(other instanceof Failed_4))
3452
+ return false;
3453
+ if (!this.e5s_1.equals(other.e5s_1))
3454
+ return false;
3455
+ if (!(this.f5s_1 === other.f5s_1))
3456
+ return false;
3457
+ return true;
3458
+ };
3459
+ var RuntimeFailureCode_CONTEXT_REQUIRED_instance;
3460
+ var RuntimeFailureCode_INVALID_CONTEXT_instance;
3461
+ var RuntimeFailureCode_CONTEXT_NOT_FOUND_instance;
3462
+ var RuntimeFailureCode_AUTH_REQUIRED_instance;
3463
+ var RuntimeFailureCode_PAT_INVALID_instance;
3464
+ var RuntimeFailureCode_FORBIDDEN_instance;
3465
+ var RuntimeFailureCode_BACKEND_UNAVAILABLE_instance;
3466
+ var RuntimeFailureCode_INVALID_AUTH_URL_instance;
3467
+ var RuntimeFailureCode_entriesInitialized;
3468
+ function RuntimeFailureCode_initEntries() {
3469
+ if (RuntimeFailureCode_entriesInitialized)
3470
+ return Unit_instance;
3471
+ RuntimeFailureCode_entriesInitialized = true;
3472
+ RuntimeFailureCode_CONTEXT_REQUIRED_instance = new RuntimeFailureCode('CONTEXT_REQUIRED', 0);
3473
+ RuntimeFailureCode_INVALID_CONTEXT_instance = new RuntimeFailureCode('INVALID_CONTEXT', 1);
3474
+ RuntimeFailureCode_CONTEXT_NOT_FOUND_instance = new RuntimeFailureCode('CONTEXT_NOT_FOUND', 2);
3475
+ RuntimeFailureCode_AUTH_REQUIRED_instance = new RuntimeFailureCode('AUTH_REQUIRED', 3);
3476
+ RuntimeFailureCode_PAT_INVALID_instance = new RuntimeFailureCode('PAT_INVALID', 4);
3477
+ RuntimeFailureCode_FORBIDDEN_instance = new RuntimeFailureCode('FORBIDDEN', 5);
3478
+ RuntimeFailureCode_BACKEND_UNAVAILABLE_instance = new RuntimeFailureCode('BACKEND_UNAVAILABLE', 6);
3479
+ RuntimeFailureCode_INVALID_AUTH_URL_instance = new RuntimeFailureCode('INVALID_AUTH_URL', 7);
3480
+ }
3481
+ function RuntimeFailureCode(name, ordinal) {
3482
+ Enum.call(this, name, ordinal);
3483
+ }
3484
+ function RuntimeFailureCode_CONTEXT_REQUIRED_getInstance() {
3485
+ RuntimeFailureCode_initEntries();
3486
+ return RuntimeFailureCode_CONTEXT_REQUIRED_instance;
3487
+ }
3488
+ function RuntimeFailureCode_INVALID_CONTEXT_getInstance() {
3489
+ RuntimeFailureCode_initEntries();
3490
+ return RuntimeFailureCode_INVALID_CONTEXT_instance;
3491
+ }
3492
+ function RuntimeFailureCode_CONTEXT_NOT_FOUND_getInstance() {
3493
+ RuntimeFailureCode_initEntries();
3494
+ return RuntimeFailureCode_CONTEXT_NOT_FOUND_instance;
3495
+ }
3496
+ function RuntimeFailureCode_AUTH_REQUIRED_getInstance() {
3497
+ RuntimeFailureCode_initEntries();
3498
+ return RuntimeFailureCode_AUTH_REQUIRED_instance;
3499
+ }
3500
+ function RuntimeFailureCode_PAT_INVALID_getInstance() {
3501
+ RuntimeFailureCode_initEntries();
3502
+ return RuntimeFailureCode_PAT_INVALID_instance;
3503
+ }
3504
+ function RuntimeFailureCode_FORBIDDEN_getInstance() {
3505
+ RuntimeFailureCode_initEntries();
3506
+ return RuntimeFailureCode_FORBIDDEN_instance;
3507
+ }
3508
+ function RuntimeFailureCode_BACKEND_UNAVAILABLE_getInstance() {
3509
+ RuntimeFailureCode_initEntries();
3510
+ return RuntimeFailureCode_BACKEND_UNAVAILABLE_instance;
3511
+ }
3512
+ function RuntimeFailureCode_INVALID_AUTH_URL_getInstance() {
3513
+ RuntimeFailureCode_initEntries();
3514
+ return RuntimeFailureCode_INVALID_AUTH_URL_instance;
3515
+ }
3516
+ function UserSessionAccess_init_$Init$(provider, $this) {
3517
+ UserSessionAccess.call($this, UserSessionAccess$_init_$slambda_ukeg7x_0(provider, null));
3518
+ return $this;
3519
+ }
3520
+ function UserSessionAccess_init_$Create$(provider) {
3521
+ return UserSessionAccess_init_$Init$(provider, objectCreate(protoOf(UserSessionAccess)));
3522
+ }
3523
+ function UserSessionAccess$_init_$slambda_ukeg7x($provider, resultContinuation) {
3524
+ this.a64_1 = $provider;
3525
+ CoroutineImpl.call(this, resultContinuation);
3526
+ }
3527
+ protoOf(UserSessionAccess$_init_$slambda_ukeg7x).d64 = function (apiUrl, env, $completion) {
3528
+ var tmp = this.e64(apiUrl, env, $completion);
3529
+ tmp.y8_1 = Unit_instance;
3530
+ tmp.z8_1 = null;
3531
+ return tmp.e9();
3532
+ };
3533
+ protoOf(UserSessionAccess$_init_$slambda_ukeg7x).r9 = function (p1, p2, $completion) {
3534
+ var tmp = (!(p1 == null) ? typeof p1 === 'string' : false) ? p1 : THROW_CCE();
3535
+ return this.d64(tmp, (p2 == null ? true : typeof p2 === 'string') ? p2 : THROW_CCE(), $completion);
3536
+ };
3537
+ protoOf(UserSessionAccess$_init_$slambda_ukeg7x).e9 = function () {
3538
+ var suspendResult = this.y8_1;
3539
+ $sm: do
3540
+ try {
3541
+ var tmp = this.w8_1;
3542
+ switch (tmp) {
3543
+ case 0:
3544
+ this.x8_1 = 2;
3545
+ this.w8_1 = 1;
3546
+ var tmp_0 = _ProjectApiUrl___init__impl__tmjeh7(this.b64_1);
3547
+ var tmp0_elvis_lhs = this.c64_1;
3548
+ suspendResult = this.a64_1.h5t(new CredentialRequest(tmp_0, null, _CredentialEnvName___init__impl__w41seg(tmp0_elvis_lhs == null ? 'DSBUILDER_API_KEY' : tmp0_elvis_lhs), CredentialPolicy_AUTO_getInstance()), this);
3549
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
3550
+ return suspendResult;
3551
+ }
3552
+
3553
+ continue $sm;
3554
+ case 1:
3555
+ return suspendResult;
3556
+ case 2:
3557
+ throw this.z8_1;
3558
+ }
3559
+ } catch ($p) {
3560
+ var e = $p;
3561
+ if (this.x8_1 === 2) {
3562
+ throw e;
3563
+ } else {
3564
+ this.w8_1 = this.x8_1;
3565
+ this.z8_1 = e;
3566
+ }
3567
+ }
3568
+ while (true);
3569
+ };
3570
+ protoOf(UserSessionAccess$_init_$slambda_ukeg7x).e64 = function (apiUrl, env, completion) {
3571
+ var i = new UserSessionAccess$_init_$slambda_ukeg7x(this.a64_1, completion);
3572
+ i.b64_1 = apiUrl;
3573
+ i.c64_1 = env;
3574
+ return i;
3575
+ };
3576
+ function UserSessionAccess$_init_$slambda_ukeg7x_0($provider, resultContinuation) {
3577
+ var i = new UserSessionAccess$_init_$slambda_ukeg7x($provider, resultContinuation);
3578
+ var l = function (apiUrl, env, $completion) {
3579
+ return i.d64(apiUrl, env, $completion);
3580
+ };
3581
+ l.$arity = 2;
3582
+ return l;
3583
+ }
3584
+ function UserSessionAccess(resolveCredential) {
3585
+ this.f64_1 = resolveCredential;
3586
+ }
3587
+ protoOf(UserSessionAccess).g64 = function (apiUrl, credentialEnvName, $completion) {
3588
+ return this.f64_1(apiUrl, credentialEnvName, $completion);
3589
+ };
3590
+ protoOf(UserSessionAccess).h64 = function (apiUrl, credentialEnvName, $completion, $super) {
3591
+ credentialEnvName = credentialEnvName === VOID ? null : credentialEnvName;
3592
+ return $super === VOID ? this.g64(apiUrl, credentialEnvName, $completion) : $super.g64.call(this, apiUrl, credentialEnvName, $completion);
3593
+ };
3594
+ //region block: post-declaration
3595
+ protoOf(UnavailableTokenClient).r4x = username;
3596
+ protoOf(UnavailableTokenClient).u4x = clientCredentials;
3597
+ protoOf(LocalProjectContextReader).l5s = requireContext_0;
3598
+ //endregion
3599
+ //region block: init
3600
+ UnavailableProcessRunner_instance = new UnavailableProcessRunner();
3601
+ EmptyCredentialStore_instance = new EmptyCredentialStore();
3602
+ UnavailableTokenClient_instance = new UnavailableTokenClient();
3603
+ NotFound_instance = new NotFound();
3604
+ //endregion
3605
+ //region block: exports
3606
+ _.$_$ = _.$_$ || {};
3607
+ _.$_$.a = ClientRuntime;
3608
+ _.$_$.b = ContextResolver;
3609
+ _.$_$.c = Link;
3610
+ _.$_$.d = Local;
3611
+ _.$_$.e = CredentialProvider;
3612
+ _.$_$.f = CredentialRequest;
3613
+ _.$_$.g = Failed_3;
3614
+ _.$_$.h = Selected;
3615
+ _.$_$.i = DraftEditOptions;
3616
+ _.$_$.j = Executed;
3617
+ _.$_$.k = Failed_1;
3618
+ _.$_$.l = DraftOperationRunner;
3619
+ _.$_$.m = ProjectApiUrlProvider;
3620
+ _.$_$.n = Failed_2;
3621
+ _.$_$.o = Found_0;
3622
+ _.$_$.p = ProjectContextReader;
3623
+ _.$_$.q = RuntimeRequestResolver;
3624
+ _.$_$.r = RuntimeRequest;
3625
+ _.$_$.s = Failed_4;
3626
+ _.$_$.t = Resolved;
3627
+ _.$_$.u = UserSessionAccess;
3628
+ _.$_$.v = coreApplicationModule;
3629
+ _.$_$.w = DesignSystemLink_getInstance;
3630
+ //endregion
3631
+ return _;
3632
+ }(module.exports, require('./kotlin-kotlin-stdlib.js'), require('./design-system-builder-frontend-core-auth.js'), require('./design-system-builder-frontend-core-process.js'), require('./design-system-builder-frontend-core-domain.js'), require('./design-system-builder-frontend-core-workspace.js'), require('./projects-core-koin-core.js'), require('./design-system-builder-frontend-core-network.js')));
3633
+
3634
+ //# sourceMappingURL=design-system-builder-frontend-core-application.js.map