@saasquatch/vanilla-components 1.2.6 → 1.2.8-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 (44) hide show
  1. package/LICENSE +21 -21
  2. package/dist/cjs/{WidgetHost-fce29ef5.js → WidgetHost-71b013eb.js} +195 -195
  3. package/dist/cjs/sqh-close-button.cjs.entry.js +1 -1
  4. package/dist/cjs/sqh-copy-button_12.cjs.entry.js +154 -154
  5. package/dist/cjs/sqh-referral-code.cjs.entry.js +1 -1
  6. package/dist/collection/components/copy-button/copy-button.js +22 -22
  7. package/dist/collection/components/copy-link-button/copy-link-button.js +15 -15
  8. package/dist/collection/components/global-container/global-container.js +8 -8
  9. package/dist/collection/components/image-component/image-component.js +10 -10
  10. package/dist/collection/components/partner-stat-component/partner-stat-component.js +2 -2
  11. package/dist/collection/components/referral-list/referral-list.js +51 -51
  12. package/dist/collection/components/share-button/share-button.js +19 -19
  13. package/dist/collection/components/share-button-container/share-button-container.js +31 -31
  14. package/dist/collection/components/stat-component/stat-component.js +2 -2
  15. package/dist/collection/components/stats-container/stats-container.js +4 -4
  16. package/dist/collection/components/text-component/text-component.js +13 -13
  17. package/dist/collection/entrypoint.js +34 -34
  18. package/dist/collection/services/WidgetHost.js +195 -195
  19. package/dist/esm/{WidgetHost-903fb7cc.js → WidgetHost-9c337319.js} +195 -195
  20. package/dist/esm/sqh-close-button.entry.js +1 -1
  21. package/dist/esm/sqh-copy-button_12.entry.js +154 -154
  22. package/dist/esm/sqh-referral-code.entry.js +1 -1
  23. package/dist/esm-es5/sqh-close-button.entry.js +1 -1
  24. package/dist/esm-es5/sqh-copy-button_12.entry.js +9 -9
  25. package/dist/esm-es5/sqh-referral-code.entry.js +1 -1
  26. package/dist/types/components/share-button-container/share-button-container.d.ts +24 -24
  27. package/dist/types/components.d.ts +46 -46
  28. package/dist/types/saasquatch.d.ts +105 -105
  29. package/dist/widget-components/entrypoint.js +34 -34
  30. package/dist/widget-components/{p-50ae8f2b.entry.js → p-366f1663.entry.js} +1 -1
  31. package/dist/widget-components/{p-131a5c4a.entry.js → p-54ea7a00.entry.js} +1 -1
  32. package/dist/widget-components/p-58be1132.system.js +1 -1
  33. package/dist/widget-components/{p-8baa34a0.entry.js → p-71e912a2.entry.js} +6 -6
  34. package/dist/widget-components/{p-b9fcb846.system.entry.js → p-b17efca4.system.entry.js} +1 -1
  35. package/dist/widget-components/p-c5f70ddc.system.entry.js +8 -0
  36. package/dist/widget-components/{p-da180bcd.system.entry.js → p-c8bc8c77.system.entry.js} +1 -1
  37. package/dist/widget-components/widget-components.esm.js +1 -1
  38. package/docs/raisins.json +1 -1
  39. package/package.json +97 -97
  40. package/readme.md +52 -52
  41. package/dist/widget-components/p-1b8f2cfc.system.entry.js +0 -8
  42. /package/dist/esm-es5/{WidgetHost-903fb7cc.js → WidgetHost-9c337319.js} +0 -0
  43. /package/dist/widget-components/{p-e692beaf.system.js → p-8e232564.system.js} +0 -0
  44. /package/dist/widget-components/{p-ffeb02d1.js → p-edd43dbc.js} +0 -0
@@ -10167,10 +10167,10 @@ const API = {
10167
10167
  };
10168
10168
  return apolloClient()
10169
10169
  .mutate({
10170
- mutation: src `
10171
- mutation ($eventMeta: UserAnalyticsEvent!) {
10172
- createUserAnalyticsEvent(eventMeta: $eventMeta)
10173
- }
10170
+ mutation: src `
10171
+ mutation ($eventMeta: UserAnalyticsEvent!) {
10172
+ createUserAnalyticsEvent(eventMeta: $eventMeta)
10173
+ }
10174
10174
  `,
10175
10175
  variables,
10176
10176
  })
@@ -10187,21 +10187,21 @@ const API = {
10187
10187
  return apolloClient();
10188
10188
  },
10189
10189
  getUserFragment(userFragment, fragmentVariables) {
10190
- const fragment = src `
10191
- fragment UserFragment on User {
10192
- ${userFragment}
10190
+ const fragment = src `
10191
+ fragment UserFragment on User {
10192
+ ${userFragment}
10193
10193
  }`;
10194
10194
  const { userId, accountId } = widgetIdent();
10195
10195
  const variables = Object.assign(Object.assign({}, fragmentVariables), { userId,
10196
10196
  accountId });
10197
10197
  return this.getClient().query({
10198
- query: src `
10199
- query ($userId: String!, $accountId: String!, $offset: Int) {
10200
- user(id: $userId, accountId: $accountId) {
10201
- ...UserFragment
10202
- }
10203
- }
10204
- ${fragment}
10198
+ query: src `
10199
+ query ($userId: String!, $accountId: String!, $offset: Int) {
10200
+ user(id: $userId, accountId: $accountId) {
10201
+ ...UserFragment
10202
+ }
10203
+ }
10204
+ ${fragment}
10205
10205
  `,
10206
10206
  variables,
10207
10207
  });
@@ -10219,22 +10219,22 @@ const API = {
10219
10219
  };
10220
10220
  return this.getClient()
10221
10221
  .query({
10222
- query: src `
10223
- query (
10224
- $userId: String!
10225
- $accountId: String!
10226
- $programId: ID
10227
- $engagementMedium: UserEngagementMedium!
10228
- ) {
10229
- user(id: $userId, accountId: $accountId) {
10230
- shareLink(
10231
- programId: $programId
10232
- engagementMedium: $engagementMedium
10233
- shareMedium: DIRECT
10234
- useCleanLink: true
10235
- )
10236
- }
10237
- }
10222
+ query: src `
10223
+ query (
10224
+ $userId: String!
10225
+ $accountId: String!
10226
+ $programId: ID
10227
+ $engagementMedium: UserEngagementMedium!
10228
+ ) {
10229
+ user(id: $userId, accountId: $accountId) {
10230
+ shareLink(
10231
+ programId: $programId
10232
+ engagementMedium: $engagementMedium
10233
+ shareMedium: DIRECT
10234
+ useCleanLink: true
10235
+ )
10236
+ }
10237
+ }
10238
10238
  `,
10239
10239
  variables,
10240
10240
  })
@@ -10262,62 +10262,62 @@ const API = {
10262
10262
  };
10263
10263
  return this.getClient()
10264
10264
  .query({
10265
- query: src `
10266
- query (
10267
- $userId: String!
10268
- $accountId: String!
10269
- $offset: Int!
10270
- $limit: Int!
10271
- $programId: ID
10272
- $programId_exists: Boolean!
10273
- ) {
10274
- user(id: $userId, accountId: $accountId) {
10275
- locale
10276
- referrals(
10277
- limit: $limit
10278
- offset: $offset
10279
- filter: {
10280
- programId_eq: $programId
10281
- programId_exists: $programId_exists
10282
- }
10283
- ) {
10284
- totalCount
10285
- data {
10286
- dateConverted
10287
- dateReferralStarted
10288
- referredUser {
10289
- firstName
10290
- lastName
10291
- }
10292
- rewards(
10293
- filter: { userId_eq: $userId, accountId_eq: $accountId }
10294
- ) {
10295
- prettyValue
10296
- dateExpires
10297
- statuses
10298
- meta {
10299
- message
10300
- }
10301
- }
10302
- }
10303
- }
10265
+ query: src `
10266
+ query (
10267
+ $userId: String!
10268
+ $accountId: String!
10269
+ $offset: Int!
10270
+ $limit: Int!
10271
+ $programId: ID
10272
+ $programId_exists: Boolean!
10273
+ ) {
10274
+ user(id: $userId, accountId: $accountId) {
10275
+ locale
10276
+ referrals(
10277
+ limit: $limit
10278
+ offset: $offset
10279
+ filter: {
10280
+ programId_eq: $programId
10281
+ programId_exists: $programId_exists
10282
+ }
10283
+ ) {
10284
+ totalCount
10285
+ data {
10286
+ dateConverted
10287
+ dateReferralStarted
10288
+ referredUser {
10289
+ firstName
10290
+ lastName
10291
+ }
10292
+ rewards(
10293
+ filter: { userId_eq: $userId, accountId_eq: $accountId }
10294
+ ) {
10295
+ prettyValue
10296
+ dateExpires
10297
+ statuses
10298
+ meta {
10299
+ message
10300
+ }
10301
+ }
10302
+ }
10303
+ }
10304
10304
  ${showReferrer
10305
- ? `referredByReferral(programId: $programId) {
10306
- referrerUser {
10307
- firstName
10308
- lastName
10309
- }
10310
- dateReferralStarted
10311
- rewards(
10312
- filter: { userId_eq: $userId, accountId_eq: $accountId }
10313
- ) {
10314
- prettyValue
10315
- statuses
10316
- }
10305
+ ? `referredByReferral(programId: $programId) {
10306
+ referrerUser {
10307
+ firstName
10308
+ lastName
10309
+ }
10310
+ dateReferralStarted
10311
+ rewards(
10312
+ filter: { userId_eq: $userId, accountId_eq: $accountId }
10313
+ ) {
10314
+ prettyValue
10315
+ statuses
10316
+ }
10317
10317
  }`
10318
- : ""}
10319
- }
10320
- }
10318
+ : ""}
10319
+ }
10320
+ }
10321
10321
  `,
10322
10322
  variables,
10323
10323
  })
@@ -10348,70 +10348,70 @@ const API = {
10348
10348
  };
10349
10349
  return this.getClient()
10350
10350
  .query({
10351
- query: src `
10352
- query (
10353
- $userId: String!
10354
- $accountId: String!
10355
- $programId: ID
10356
- $programId_exists: Boolean!
10357
- ) {
10358
- user(id: $userId, accountId: $accountId) {
10359
- referralsCount: referrals(
10360
- filter: {
10361
- programId_eq: $programId
10362
- programId_exists: $programId_exists
10363
- }
10364
- ) {
10365
- totalCount
10366
- }
10367
- referralsMonth: referrals(
10368
- filter: {
10369
- programId_eq: $programId
10370
- programId_exists: $programId_exists
10371
- dateReferralStarted_timeframe: "this_month"
10372
- }
10373
- ) {
10374
- totalCount
10375
- }
10376
- referralsWeek: referrals(
10377
- filter: {
10378
- programId_eq: $programId
10379
- programId_exists: $programId_exists
10380
- dateReferralStarted_timeframe: "this_week"
10381
- }
10382
- ) {
10383
- totalCount
10384
- }
10385
- rewardsCount: rewards(
10386
- filter: {
10387
- programId_eq: $programId
10388
- programId_exists: $programId_exists
10389
- }
10390
- ) {
10391
- totalCount
10392
- }
10393
- rewardsMonth: rewards(
10394
- filter: {
10395
- programId_eq: $programId
10396
- programId_exists: $programId_exists
10397
- dateGiven_timeframe: "this_month"
10398
- }
10399
- ) {
10400
- totalCount
10401
- }
10402
- rewardsWeek: rewards(
10403
- filter: {
10404
- programId_eq: $programId
10405
- programId_exists: $programId_exists
10406
- dateGiven_timeframe: "this_week"
10407
- }
10408
- ) {
10409
- totalCount
10410
- }
10411
- rewardBalances(programId: $programId)
10412
- rewardBalancesGlobal: rewardBalances
10413
- }
10414
- }
10351
+ query: src `
10352
+ query (
10353
+ $userId: String!
10354
+ $accountId: String!
10355
+ $programId: ID
10356
+ $programId_exists: Boolean!
10357
+ ) {
10358
+ user(id: $userId, accountId: $accountId) {
10359
+ referralsCount: referrals(
10360
+ filter: {
10361
+ programId_eq: $programId
10362
+ programId_exists: $programId_exists
10363
+ }
10364
+ ) {
10365
+ totalCount
10366
+ }
10367
+ referralsMonth: referrals(
10368
+ filter: {
10369
+ programId_eq: $programId
10370
+ programId_exists: $programId_exists
10371
+ dateReferralStarted_timeframe: "this_month"
10372
+ }
10373
+ ) {
10374
+ totalCount
10375
+ }
10376
+ referralsWeek: referrals(
10377
+ filter: {
10378
+ programId_eq: $programId
10379
+ programId_exists: $programId_exists
10380
+ dateReferralStarted_timeframe: "this_week"
10381
+ }
10382
+ ) {
10383
+ totalCount
10384
+ }
10385
+ rewardsCount: rewards(
10386
+ filter: {
10387
+ programId_eq: $programId
10388
+ programId_exists: $programId_exists
10389
+ }
10390
+ ) {
10391
+ totalCount
10392
+ }
10393
+ rewardsMonth: rewards(
10394
+ filter: {
10395
+ programId_eq: $programId
10396
+ programId_exists: $programId_exists
10397
+ dateGiven_timeframe: "this_month"
10398
+ }
10399
+ ) {
10400
+ totalCount
10401
+ }
10402
+ rewardsWeek: rewards(
10403
+ filter: {
10404
+ programId_eq: $programId
10405
+ programId_exists: $programId_exists
10406
+ dateGiven_timeframe: "this_week"
10407
+ }
10408
+ ) {
10409
+ totalCount
10410
+ }
10411
+ rewardBalances(programId: $programId)
10412
+ rewardBalancesGlobal: rewardBalances
10413
+ }
10414
+ }
10415
10415
  `,
10416
10416
  variables,
10417
10417
  })
@@ -10429,12 +10429,12 @@ const API = {
10429
10429
  };
10430
10430
  return this.getClient()
10431
10431
  .query({
10432
- query: src `
10433
- query ($userId: String!, $accountId: String!, $programId: ID!) {
10434
- user(id: $userId, accountId: $accountId) {
10435
- referralCode(programId: $programId)
10436
- }
10437
- }
10432
+ query: src `
10433
+ query ($userId: String!, $accountId: String!, $programId: ID!) {
10434
+ user(id: $userId, accountId: $accountId) {
10435
+ referralCode(programId: $programId)
10436
+ }
10437
+ }
10438
10438
  `,
10439
10439
  variables,
10440
10440
  })
@@ -10457,33 +10457,33 @@ const API = {
10457
10457
  };
10458
10458
  return this.getClient()
10459
10459
  .query({
10460
- query: src `
10461
- query (
10462
- $userId: String!
10463
- $accountId: String!
10464
- $programId: ID!
10465
- $rewardKey: String!
10466
- ) {
10467
- user(id: $userId, accountId: $accountId) {
10468
- referredByReferral(programId: $programId) {
10469
- referrerUser {
10470
- referralCode(programId: $programId)
10471
- }
10472
- }
10473
- rewards(
10474
- filter: {
10475
- programId_eq: $programId
10476
- programRewardKey_eq: $rewardKey
10477
- }
10478
- ) {
10479
- count
10480
- totalCount
10481
- data {
10482
- fuelTankCode
10483
- }
10484
- }
10485
- }
10486
- }
10460
+ query: src `
10461
+ query (
10462
+ $userId: String!
10463
+ $accountId: String!
10464
+ $programId: ID!
10465
+ $rewardKey: String!
10466
+ ) {
10467
+ user(id: $userId, accountId: $accountId) {
10468
+ referredByReferral(programId: $programId) {
10469
+ referrerUser {
10470
+ referralCode(programId: $programId)
10471
+ }
10472
+ }
10473
+ rewards(
10474
+ filter: {
10475
+ programId_eq: $programId
10476
+ programRewardKey_eq: $rewardKey
10477
+ }
10478
+ ) {
10479
+ count
10480
+ totalCount
10481
+ data {
10482
+ fuelTankCode
10483
+ }
10484
+ }
10485
+ }
10486
+ }
10487
10487
  `,
10488
10488
  variables,
10489
10489
  })
@@ -10502,20 +10502,20 @@ const API = {
10502
10502
  };
10503
10503
  return this.getClient()
10504
10504
  .query({
10505
- query: src `
10506
- query($userId: String!, $accountId: String!, $programId: ID, $engagementMedium: UserEngagementMedium!) {
10507
- user(id: $userId, accountId: $accountId) {
10508
- ${mediums[0]}:messageLink(programId: $programId, engagementMedium: $engagementMedium, shareMedium: ${mediums[0]})
10509
- ${mediums[1]}:messageLink(programId: $programId, engagementMedium: $engagementMedium, shareMedium: ${mediums[1]})
10510
- ${mediums[2]}:messageLink(programId: $programId, engagementMedium: $engagementMedium, shareMedium: ${mediums[2]})
10511
- ${mediums[3]}:messageLink(programId: $programId, engagementMedium: $engagementMedium, shareMedium: ${mediums[3]})
10512
- ${mediums[4]}:messageLink(programId: $programId, engagementMedium: $engagementMedium, shareMedium: ${mediums[4]})
10513
- ${mediums[5]}:messageLink(programId: $programId, engagementMedium: $engagementMedium, shareMedium: ${mediums[5]})
10514
- ${mediums[6]}:messageLink(programId: $programId, engagementMedium: $engagementMedium, shareMedium: ${mediums[6]})
10515
- ${mediums[7]}:messageLink(programId: $programId, engagementMedium: $engagementMedium, shareMedium: ${mediums[7]})
10516
- ${mediums[8]}:messageLink(programId: $programId, engagementMedium: $engagementMedium, shareMedium: ${mediums[8]})
10517
- }
10518
- }
10505
+ query: src `
10506
+ query($userId: String!, $accountId: String!, $programId: ID, $engagementMedium: UserEngagementMedium!) {
10507
+ user(id: $userId, accountId: $accountId) {
10508
+ ${mediums[0]}:messageLink(programId: $programId, engagementMedium: $engagementMedium, shareMedium: ${mediums[0]})
10509
+ ${mediums[1]}:messageLink(programId: $programId, engagementMedium: $engagementMedium, shareMedium: ${mediums[1]})
10510
+ ${mediums[2]}:messageLink(programId: $programId, engagementMedium: $engagementMedium, shareMedium: ${mediums[2]})
10511
+ ${mediums[3]}:messageLink(programId: $programId, engagementMedium: $engagementMedium, shareMedium: ${mediums[3]})
10512
+ ${mediums[4]}:messageLink(programId: $programId, engagementMedium: $engagementMedium, shareMedium: ${mediums[4]})
10513
+ ${mediums[5]}:messageLink(programId: $programId, engagementMedium: $engagementMedium, shareMedium: ${mediums[5]})
10514
+ ${mediums[6]}:messageLink(programId: $programId, engagementMedium: $engagementMedium, shareMedium: ${mediums[6]})
10515
+ ${mediums[7]}:messageLink(programId: $programId, engagementMedium: $engagementMedium, shareMedium: ${mediums[7]})
10516
+ ${mediums[8]}:messageLink(programId: $programId, engagementMedium: $engagementMedium, shareMedium: ${mediums[8]})
10517
+ }
10518
+ }
10519
10519
  `,
10520
10520
  variables,
10521
10521
  })
@@ -1,6 +1,6 @@
1
1
  import { r as registerInstance, h, g as getElement } from './index-8ea8b6d8.js';
2
2
  import './_commonjsHelpers-1d681858.js';
3
- import { A as API, w as widgetIdent } from './WidgetHost-903fb7cc.js';
3
+ import { A as API, w as widgetIdent } from './WidgetHost-9c337319.js';
4
4
 
5
5
  const closeButtonCss = "sqh-close-button .squatch-header-close{position:absolute;top:4px;right:6px;background:transparent;border:0;color:#4486e1;font-size:12px}sqh-close-button .squatch-header-close:hover{text-decoration:underline}";
6
6