@kompasid/lit-web-components 0.9.42 → 0.9.44

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.
@@ -15,7 +15,7 @@ import { getFontAwesomeIcon } from '../../utils/fontawesome-setup.js'
15
15
  import { deviceType } from '../../utils/deviceType.js'
16
16
  import { formatRupiah } from '../../utils/formatRupiah.js'
17
17
  import { addGoogleFonts } from '../../utils/googleFont.js'
18
- import { redirectToRegister, redirectToLogin } from '../../utils/cta.js'
18
+ import { redirectToLogin } from '../../utils/cta.js'
19
19
  import { customFetch } from '../../utils/customFetch.js'
20
20
  import { getCookie } from '../../utils/getCookies.js'
21
21
  import { getLoginGuest } from '../../utils/api/getLoginGuest.js'
@@ -635,80 +635,109 @@ export class KompasIdPaywallBody extends LitElement {
635
635
 
636
636
  private headerSection(type: PaywallType, title: string) {
637
637
  let buttonContent
638
- const textColorClass = this.isDark ? 'text-blue-300' : 'text-blue-600'
638
+ const isPro =
639
+ this.type === 'proMiningArticle' || this.type === 'proMiningOutlook'
640
+ const textColorDefault = isPro ? 'text-grey-600' : 'text-blue-600'
641
+ const textColorClass = this.isDark ? 'text-blue-300' : textColorDefault
639
642
  const buttonTextColorClass = this.isDark ? 'text-white' : 'text-grey-600'
640
643
  const isPrevHistoryExist = window.history.length > 1
641
644
 
642
645
  if (type === 'epaper' && isPrevHistoryExist) {
643
646
  buttonContent = html` <button
644
647
  @click=${this.redirectToPrevUrl}
645
- class="hidden md:block w-8 h-8 pl-4 ${textColorClass}"
648
+ class="absolute left-2.5 -top-1.5 hidden md:flex w-10 h-10 justify-center items-center ${textColorClass}"
646
649
  >
647
- ${unsafeSVG(getFontAwesomeIcon('fas', 'arrow-left'))}
650
+ ${unsafeSVG(getFontAwesomeIcon('fas', 'arrow-left', 20, 20))}
648
651
  </button>`
649
652
  } else if (type === 'proMiningOutlook' && isPrevHistoryExist) {
650
653
  buttonContent = html` <button
651
654
  @click=${this.redirectToPrevUrl}
652
- class="hidden md:block w-8 h-8 pl-4 ${textColorClass}"
655
+ class="absolute left-2.5 -top-1.5 hidden md:flex w-10 h-10 justify-center items-center ${textColorClass}"
653
656
  >
654
- ${unsafeSVG(getFontAwesomeIcon('fas', 'arrow-left'))}
657
+ ${unsafeSVG(getFontAwesomeIcon('fas', 'arrow-left', 20, 20))}
655
658
  </button>`
656
659
  } else if (type === 'audio') {
657
660
  buttonContent = html` <button
658
661
  @click=${this.togglePaywall}
659
- class="hidden md:block w-8 h-8 pl-4 ${textColorClass}"
662
+ class="absolute left-2.5 -top-1.5 hidden md:flex w-10 h-10 justify-center items-center ${textColorClass}"
660
663
  >
661
- ${unsafeSVG(getFontAwesomeIcon('fas', 'xmark', 24, 24))}
664
+ ${unsafeSVG(getFontAwesomeIcon('fas', 'xmark', 28, 28))}
662
665
  </button>`
663
666
  } else {
664
667
  buttonContent = nothing
665
668
  }
666
669
 
667
- const headerClass = `text-base flex justify-center self-center md:block md:text-xl ${buttonTextColorClass} text-center font-lora font-bold tracking-wide md:tracking-normal max-w-xs sm:max-w-lg md:w-full md:max-w-full ${
670
+ const headerClass = `text-base flex justify-center self-center md:block md:text-xl ${buttonTextColorClass} text-center font-lora font-bold tracking-normal max-w-xs sm:max-w-lg md:w-full md:max-w-[492px] ${
668
671
  type === 'audio' && 'sm:px-16 md:px-20'
669
672
  }`
670
673
 
671
674
  return html`
672
- <div class="flex w-full items-start justify-center">
675
+ <div class="flex w-full items-start justify-center relative md:px-10">
673
676
  ${buttonContent}
674
677
  <h4 class=${headerClass}>${title}</h4>
675
- ${type === 'epaper' || type === 'audio'
676
- ? html`<div class="w-10 hidden md:flex"></div>`
677
- : nothing}
678
678
  </div>
679
679
  `
680
680
  }
681
681
 
682
+ private excerptSection(excerpt: string) {
683
+ return excerpt
684
+ ? html` <p
685
+ class="text-sm md:text-base ${this.isDark
686
+ ? 'text-white'
687
+ : 'text-grey-600'} font-sans mt-2 md:mt-4 max-w-[492px] text-center"
688
+ >
689
+ ${excerpt}
690
+ </p>`
691
+ : nothing
692
+ }
693
+
682
694
  private descriptionSection(data: Array<string>) {
683
- const spaceYClass =
684
- this.type === 'audio' ? 'space-y-2 md:space-y-1' : 'space-y-2'
695
+ const isPro =
696
+ this.type === 'proMiningArticle' || this.type === 'proMiningOutlook'
685
697
  const textColorClass = this.isDark ? 'text-green-400' : 'text-green-500'
686
698
  const buttonTextColorClass = this.isDark ? 'text-white' : 'text-grey-600'
699
+ const borderColorDefault = isPro ? 'border-grey-300' : 'border-blue-200'
700
+ const borderColorClass = this.isDark ? 'border-white' : borderColorDefault
687
701
 
688
- return html` <div class=" flex flex-col items-center px-4">
689
- <div class="flex flex-col md:max-w-[464px] mt-2.5 md:mt-3 ${spaceYClass}">
690
- ${data.map(
691
- item =>
692
- html`
693
- <div class="flex items-center">
694
- <div class="${textColorClass}">
695
- ${unsafeSVG(getFontAwesomeIcon('fas', 'check', 12, 12))}
696
- </div>
697
- <h6
698
- class="text-sm md:text-base ml-0.5 md:ml-1 ${buttonTextColorClass}"
699
- >
700
- ${item}
701
- </h6>
702
- </div>
703
- `
704
- )}
705
- </div>
706
- </div>`
702
+ return data.length
703
+ ? html`<div
704
+ class="md:max-w-[492px] flex flex-col items-center px-0 lg:px-4 py-4 lg:py-5 w-full border-b border-t ${borderColorClass} mt-4 lg:mt-5"
705
+ >
706
+ <div>
707
+ <div
708
+ class="font-bold font-sans ${buttonTextColorClass} w-full text-left"
709
+ >
710
+ Keuntungan Eksklusif yang Anda Dapatkan:
711
+ </div>
712
+ <div class="flex flex-col mt-2 md:mt-3 gap-2 text-left">
713
+ ${data.map(
714
+ item =>
715
+ html`
716
+ <div class="flex items-center text-left">
717
+ <div
718
+ class="${textColorClass} h-4 w-4 md:h-5 md:w-5 flex items-center justify-center"
719
+ >
720
+ ${unsafeSVG(getFontAwesomeIcon('fas', 'check', 16, 16))}
721
+ </div>
722
+ <h6
723
+ class="text-sm md:text-base ml-1 md:ml-2 ${buttonTextColorClass}"
724
+ >
725
+ ${item}
726
+ </h6>
727
+ </div>
728
+ `
729
+ )}
730
+ </div>
731
+ </div>
732
+ </div>`
733
+ : nothing
707
734
  }
708
735
 
709
736
  private ctaPackages() {
710
- const marginTopClass = this.type === 'audio' ? 'mt-4 md:mt-2' : 'mt-4'
711
- const textColorClass = this.isDark ? 'text-blue-300' : 'text-blue-600'
737
+ const isPro =
738
+ this.type === 'proMiningArticle' || this.type === 'proMiningOutlook'
739
+ const textColorDefault = isPro ? 'text-grey-600' : 'text-blue-600'
740
+ const textColorClass = this.isDark ? 'text-blue-300' : textColorDefault
712
741
  const getCtaText = this.paywallData?.informations?.cta
713
742
  ? this.paywallData?.informations?.cta.text
714
743
  : ''
@@ -717,7 +746,7 @@ export class KompasIdPaywallBody extends LitElement {
717
746
  : false
718
747
 
719
748
  return showCta
720
- ? html` <div class="flex justify-center ${marginTopClass}">
749
+ ? html` <div class="flex justify-center mt-2 md:mt-3">
721
750
  <button
722
751
  @click=${this.otherPackagesClicked}
723
752
  class="text-sm md:text-base font-bold underline ${textColorClass}"
@@ -733,7 +762,8 @@ export class KompasIdPaywallBody extends LitElement {
733
762
  const buttonTextColorClass = this.isDark ? 'text-white' : 'text-grey-600'
734
763
 
735
764
  return html`
736
- <div>
765
+ <div class="mt-4 lg:mt-5">
766
+ <span class="${buttonTextColorClass}">Sudah berlangganan?</span>
737
767
  <button
738
768
  @click=${() =>
739
769
  redirectToLogin({
@@ -744,47 +774,29 @@ export class KompasIdPaywallBody extends LitElement {
744
774
  >
745
775
  Masuk
746
776
  </button>
747
- <span class="${buttonTextColorClass}">jika sudah berlangganan.</span>
748
777
  </div>
749
778
  `
750
779
  }
751
780
 
752
781
  private regulerRegistrationSection() {
753
- const textColorClass = this.isDark ? 'text-blue-300' : 'text-blue-600'
754
- const buttonTextColorClass = this.isDark ? 'text-white' : 'text-grey-600'
755
782
  const isPro =
756
783
  this.type === 'proMiningArticle' || this.type === 'proMiningOutlook'
784
+ const textColorDefault = isPro ? 'text-grey-600' : 'text-blue-600'
785
+ const textColorClass = this.isDark ? 'text-blue-300' : textColorDefault
786
+ const buttonTextColorClass = this.isDark ? 'text-white' : 'text-grey-600'
757
787
 
758
788
  return html`
759
789
  <div
760
- class="flex flex-col items-center justify-center text-sm md:text-base"
790
+ class="flex flex-col items-center justify-center text-sm md:text-base mt-4 lg:mt-5"
761
791
  >
762
- ${!isPro
763
- ? html`
764
- <div>
765
- <button
766
- @click=${() => redirectToRegister('hard_paywall')}
767
- class="font-bold underline ${textColorClass}"
768
- >
769
- Daftar
770
- </button>
771
- <span class="${buttonTextColorClass}"
772
- >untuk kuota artikel gratis</span
773
- >
774
- </div>
775
- `
776
- : nothing}
777
792
  <div>
778
- ${!isPro
779
- ? html` <span class="${buttonTextColorClass}">atau</span>`
780
- : nothing}
793
+ <span class="${buttonTextColorClass}">Sudah berlangganan?</span>
781
794
  <button
782
795
  @click=${() => redirectToLogin({ loc: 'hard_paywall' })}
783
796
  class="font-bold underline ${textColorClass}"
784
797
  >
785
798
  Masuk
786
799
  </button>
787
- <span class="${buttonTextColorClass}">jika sudah punya akun.</span>
788
800
  </div>
789
801
  </div>
790
802
  `
@@ -836,45 +848,75 @@ export class KompasIdPaywallBody extends LitElement {
836
848
  `
837
849
  }
838
850
 
839
- private primaryPackages(product: Product) {
851
+ private renderPackage(
852
+ product: Product,
853
+ isHighlight: boolean,
854
+ isButtonSolid: boolean
855
+ ) {
840
856
  const { isDark } = this
841
- const isAudio = this.type === 'audio'
842
-
843
- const containerClass = `flex flex-wrap justify-between h-[68px] items-center rounded-lg md:mx-0 w-full max-w-xs md:max-w-sm md:w-3/5 mt-2.5${
844
- isDark ? ' bg-grey-600' : ' bg-white'
845
- }${isAudio ? ' md:mt-3' : ' md:mt-4'} border border-yellow-400 relative`
846
857
 
858
+ const containerClass = `px-4 flex flex-wrap items-center justify-between rounded-lg md:mx-0 w-full max-w-xs md:max-w-sm md:w-3/5 min-h-[68px]
859
+ ${isDark ? ' bg-grey-600' : ' bg-white'}
860
+ ${isHighlight ? 'border border-yellow-400 mt-2' : ''} relative`
847
861
  const textColorClass = isDark ? 'text-dark-7' : 'text-grey-600'
848
862
 
849
- const buttonClass = `h-8 rounded mr-4 flex items-center${
850
- isDark ? ' bg-green-300 border border-green-400' : ' bg-green-500'
851
- }`
863
+ let buttonBgColorClass = ''
864
+ if (isButtonSolid) {
865
+ buttonBgColorClass = isDark
866
+ ? 'bg-green-300 border border-green-400'
867
+ : 'bg-green-500'
868
+ } else {
869
+ buttonBgColorClass = isDark
870
+ ? ' border border-green-500 text-green-300'
871
+ : ' border border-green-500 bg-white text-green-500'
872
+ }
852
873
 
853
- const buttonTextClass = `text-xs md:text-sm font-bold py-2 px-4${
854
- isDark ? ' text-black' : ' text-white'
855
- }`
874
+ const buttonClass = `h-8 rounded ${buttonBgColorClass} flex items-center`
856
875
 
876
+ let buttonTextColor = ''
877
+ if (isButtonSolid) {
878
+ buttonTextColor = isDark ? ' text-black' : ' text-white'
879
+ } else if (isDark) {
880
+ buttonTextColor = 'text-green-300'
881
+ } else {
882
+ buttonTextColor = 'text-green-500'
883
+ }
884
+ const buttonTextClass = `text-xs md:text-sm font-bold py-2 px-4 ${buttonTextColor}`
857
885
  return html`
858
886
  <div class="${containerClass}">
859
- <div class="flex flex-col py-3 px-4">
860
- <div class="flex flex-none items-center">
861
- <h5 class="text-base md:text-lg font-bold text-orange-400">
887
+ <div class="flex flex-col gap-1">
888
+ <div class="flex items-baseline">
889
+ <h5 class="text-base font-bold text-orange-400 leading-none">
862
890
  ${formatRupiah(product.price)}
863
891
  </h5>
864
- <h6 class="text-xs md:text-base font-bold pl-1 ${textColorClass}">
892
+ <h6 class="text-xs font-bold pl-1 ${textColorClass} leading-none">
865
893
  / ${product.periode}
866
894
  </h6>
867
895
  </div>
868
- ${product.savingPrice
896
+ ${product.priceSlice || product.saveLabel
869
897
  ? html`
870
- <div class="flex items-center">
871
- <p class="text-xs ${textColorClass}">
872
- hanya
873
- <span class="text-orange-400"
874
- >${formatRupiah(product.savingPrice)}</span
875
- >
876
- / bulan
877
- </p>
898
+ <div class="flex flex-row gap-2">
899
+ ${product.priceSlice
900
+ ? html`
901
+ <div class="flex items-center text-xs font-sans">
902
+ <span
903
+ class="${isDark
904
+ ? 'text-white'
905
+ : 'text-grey-400'} line-through"
906
+ >${formatRupiah(product.priceSlice)}</span
907
+ >
908
+ </div>
909
+ `
910
+ : nothing}
911
+ ${product.saveLabel
912
+ ? html`
913
+ <div
914
+ class="flex font-bold items-center text-xs font-sans bg-red-100 rounded p-1"
915
+ >
916
+ <span class="text-red-500">${product.saveLabel}</span>
917
+ </div>
918
+ `
919
+ : nothing}
878
920
  </div>
879
921
  `
880
922
  : nothing}
@@ -892,82 +934,28 @@ export class KompasIdPaywallBody extends LitElement {
892
934
  >
893
935
  <h6 class="${buttonTextClass}">Langganan</h6>
894
936
  </button>
895
- <div class="absolute -top-2 left-4">
896
- <div class="rounded bg-yellow-300 px-2 py-0.5 text-xs">
897
- <b class="text-grey-600">Harga Terbaik</b>
898
- </div>
899
- </div>
900
- </div>
901
- `
902
- }
903
-
904
- private secondaryPackages(product: Product) {
905
- const { isDark } = this
906
- const isAudio = this.type === 'audio'
907
-
908
- const containerClass = `flex flex-wrap items-center justify-between py-3 px-4 rounded-lg md:mx-0 w-full h-[68px] max-w-xs md:max-w-sm md:w-3/5 mt-3${
909
- isDark ? ' bg-grey-600' : ' bg-white'
910
- }${isAudio ? ' md:mt-2.5' : ' md:mt-4'}`
911
-
912
- const textColorClass = isDark ? 'text-dark-7' : 'text-grey-600'
913
-
914
- const buttonClass = `h-8 rounded border border-green-500${
915
- isDark ? ' text-green-300' : ' bg-white text-green-500'
916
- }`
917
-
918
- const buttonTextClass = `text-xs md:text-sm font-bold px-4${
919
- isDark ? ' text-green-300' : ' text-green-500'
920
- }`
921
-
922
- return html`
923
- <div class="${containerClass}">
924
- <div class="flex flex-col">
925
- <div class="flex items-center">
926
- <h5 class="text-base md:text-lg font-bold text-orange-400">
927
- ${formatRupiah(product.price)}
928
- </h5>
929
- <h6 class="text-xs md:text-base font-bold pl-1 ${textColorClass}">
930
- / ${product.periode}
931
- </h6>
932
- </div>
933
- ${product.savingPrice
934
- ? html`
935
- <div class="flex items-center">
936
- <p class="text-xs ${textColorClass}">
937
- hanya
938
- <span class="text-orange-400"
939
- >${formatRupiah(product.savingPrice)}</span
940
- >
941
- / bulan
942
- </p>
937
+ ${isHighlight
938
+ ? html`
939
+ <div class="absolute -top-2 left-4">
940
+ <div
941
+ class="rounded bg-yellow-300 px-2 h-4 items-center text-xs"
942
+ >
943
+ <b class="text-grey-600">Harga Terbaik</b>
943
944
  </div>
944
- `
945
- : nothing}
946
- </div>
947
- <button
948
- @click=${() =>
949
- this.redirectToCheckout(
950
- product.url,
951
- product.package,
952
- product.subscriptionId,
953
- product.price,
954
- product.position
955
- )}
956
- class="${buttonClass}"
957
- >
958
- <h6 class="${buttonTextClass}">Langganan</h6>
959
- </button>
945
+ </div>
946
+ `
947
+ : nothing}
960
948
  </div>
961
949
  `
962
950
  }
963
951
 
964
952
  private packagesSection(data: Packages) {
965
953
  return html`
966
- <div class="flex flex-col w-full items-center mt-8 md:mt-2 px-4">
954
+ <div
955
+ class="flex flex-col w-full items-center gap-2 md:gap-3 mt-4 md:mt-5"
956
+ >
967
957
  ${data.memberships.map(item =>
968
- item.isHighlight
969
- ? this.primaryPackages(item)
970
- : this.secondaryPackages(item)
958
+ this.renderPackage(item, item.isHighlight, item.isButtonSolid)
971
959
  )}
972
960
  ${this.freeTrialPackageSection()} ${this.freeTrialPopUp()}
973
961
  ${this.packages.swgEnable ? this.swgPackageSection() : nothing}
@@ -975,31 +963,47 @@ export class KompasIdPaywallBody extends LitElement {
975
963
  `
976
964
  }
977
965
 
966
+ // private packagesSection(data: Packages) {
967
+ // return html`
968
+ // <div class="flex flex-col w-full items-center mt-8 md:mt-2 px-4">
969
+ // ${data.memberships.map(item =>
970
+ // item.isHighlight
971
+ // ? this.primaryPackages(item)
972
+ // : this.secondaryPackages(item)
973
+ // )}
974
+ // ${this.freeTrialPackageSection()} ${this.freeTrialPopUp()}
975
+ // ${this.packages.swgEnable ? this.swgPackageSection() : nothing}
976
+ // </div>
977
+ // `
978
+ // }
979
+
978
980
  private topNavigator(type: PaywallType) {
979
981
  let icon: string
980
982
  let buttonText: string
981
983
  let clickAction: Function
982
984
 
983
985
  if (type === 'audio') {
984
- icon = getFontAwesomeIcon('fas', 'xmark')
986
+ icon = getFontAwesomeIcon('fas', 'xmark', 12, 12)
985
987
  buttonText = 'Tutup'
986
988
  clickAction = this.togglePaywall.bind(this)
987
989
  } else {
988
- icon = getFontAwesomeIcon('fas', 'arrow-left')
990
+ icon = getFontAwesomeIcon('fas', 'arrow-left', 10, 10)
989
991
  buttonText = 'Kembali'
990
992
  clickAction = this.redirectToPrevUrl.bind(this)
991
993
  }
992
994
 
993
995
  return html`
994
- <div class="flex md:hidden w-full pb-4">
996
+ <div class="flex md:hidden w-full">
995
997
  <button
996
998
  @click=${clickAction}
997
- class="text-xs md:text-lg text-white flex flex-row"
999
+ class="text-xs md:text-lg font-sans font-bold text-white flex flex-row h-8 px-4 items-center gap-1"
998
1000
  >
999
- <div class="icon-lg icon-white w-4 h-4 mr-3.5 md:mr-5 pt-0.5">
1001
+ <div
1002
+ class="icon-lg icon-white w-4 h-4 items-center justify-center flex"
1003
+ >
1000
1004
  ${unsafeSVG(icon)}
1001
1005
  </div>
1002
- ${buttonText}
1006
+ <span> ${buttonText} </span>
1003
1007
  </button>
1004
1008
  </div>
1005
1009
  `
@@ -1022,14 +1026,16 @@ export class KompasIdPaywallBody extends LitElement {
1022
1026
  }
1023
1027
 
1024
1028
  private userAction() {
1029
+ const isPro =
1030
+ this.type === 'proMiningArticle' || this.type === 'proMiningOutlook'
1025
1031
  const isAudio = this.type === 'audio'
1026
1032
  const paddingClass = isAudio ? 'md:py-3.5' : 'md:py-6'
1027
- const marginClass = isAudio ? 'md:mt-4' : 'md:mt-8'
1028
- const backgroundClass = this.isDark ? 'bg-dark-4' : 'bg-blue-600'
1033
+ const backgroundDefault = isPro ? 'bg-grey-500' : 'bg-blue-600'
1034
+ const backgroundClass = this.isDark ? 'bg-dark-4' : backgroundDefault
1029
1035
 
1030
1036
  return html`
1031
1037
  <div
1032
- class="flex py-5 px-8 w-full justify-evenly rounded-b-xl mt-6 relative ${paddingClass} ${marginClass} ${backgroundClass}"
1038
+ class="flex py-5 px-8 w-full justify-evenly rounded-b-xl mt-5 relative ${paddingClass} md:mt-7 ${backgroundClass}"
1033
1039
  >
1034
1040
  ${this.helpDesk()}
1035
1041
  </div>
@@ -1039,17 +1045,21 @@ export class KompasIdPaywallBody extends LitElement {
1039
1045
  private introductoryPrice() {
1040
1046
  const textColorClass = this.isDark ? 'text-dark-7' : 'text-grey-600'
1041
1047
  return html` <div
1042
- class="flex space-x-1 h-5 md:h-max overflow-hidden md:flex-col md:space-x-0 items-center md:items-start md:w-1/2 md:justify-center"
1048
+ class="flex md:flex-col gap-1 items-center md:items-start md:w-1/2 md:justify-center"
1043
1049
  >
1044
- <div class="flex items-center">
1045
- <h5 class="text-base md:text-lg font-bold text-orange-400">
1050
+ <div class="flex items-center gap-1 shrink-0">
1051
+ <h5 class="text-base font-bold text-orange-400 leading-none">
1046
1052
  ${this.packages.swgContent.introductory.price}
1047
1053
  </h5>
1048
- <h6 class="text-xs md:text-base font-bold pl-1 ${textColorClass}">
1049
- ${this.packages.swgContent.introductory.duration}
1050
- </h6>
1054
+ ${this.packages.swgContent.introductory.duration
1055
+ ? html`
1056
+ <h6 class="text-xs font-bold ${textColorClass} leading-none">
1057
+ ${this.packages.swgContent.introductory.duration}
1058
+ </h6>
1059
+ `
1060
+ : nothing}
1051
1061
  </div>
1052
- <p class="text-xs ${textColorClass}">
1062
+ <p class="text-xs flex ${textColorClass} leading-none">
1053
1063
  ${this.packages.swgContent.introductory.description}
1054
1064
  </p>
1055
1065
  </div>`
@@ -1064,14 +1074,13 @@ export class KompasIdPaywallBody extends LitElement {
1064
1074
 
1065
1075
  private swgPackageSection() {
1066
1076
  const { isDark } = this
1067
- const isAudio = this.type === 'audio'
1068
1077
 
1069
- const containerClass = `flex flex-col space-y-2 md:space-x-2 md:space-y-0 md:flex-row justify-between items-center py-3 px-4 rounded-lg md:mx-0 w-full h-[76px] md:h-[68px] max-w-xs md:max-w-sm md:w-3/5 mt-3${
1078
+ const containerClass = `flex flex-col md:flex-row gap-1 justify-center md:justify-between items-center px-4 rounded-lg md:mx-0 w-full min-h-[76px] md:min-h-[68px] max-w-xs md:max-w-sm md:w-3/5 ${
1070
1079
  isDark ? ' bg-grey-600' : ' bg-white'
1071
- }${isAudio ? ' md:mt-2.5' : ' md:mt-4'}`
1080
+ }`
1072
1081
 
1073
1082
  const buttonClass = `border space-x-2 justify-center border-grey-400 rounded-md px-[22px] md:px-6 shadow-sm flex h-max flex-row flex-nowrap py-[5.6px] md:py-1.5 items-center${
1074
- isDark ? ' bg-grey-600' : ' bg-grey-100 border-grey-100'
1083
+ isDark ? ' bg-grey-600' : ' bg-white border-grey-100'
1075
1084
  }`
1076
1085
 
1077
1086
  const textColorClass = isDark ? 'text-dark-7' : 'text-grey-500'
@@ -1257,7 +1266,7 @@ export class KompasIdPaywallBody extends LitElement {
1257
1266
  */
1258
1267
 
1259
1268
  render() {
1260
- const isEpaper = this.type === 'epaper'
1269
+ const isEpaper = this.type === 'epaper' || this.type === 'proMiningOutlook'
1261
1270
  const isAudio = this.type === 'audio'
1262
1271
  const { isDark } = this
1263
1272
  const { isLogin } = this
@@ -1266,45 +1275,47 @@ export class KompasIdPaywallBody extends LitElement {
1266
1275
  ${isEpaper ? 'bg-transparent mx-2' : ''}
1267
1276
  ${
1268
1277
  isAudio
1269
- ? 'fixed w-full h-full inset-0 flex justify-center items-center z-index-max bg-black bg-opacity-75'
1278
+ ? 'fixed w-full h-full inset-0 flex justify-center items-center z-index-max bg-black bg-opacity-75 px-4 md:px-0'
1270
1279
  : ''
1271
1280
  }`
1272
1281
  .trim()
1273
1282
  .replace(/\s+/g, ' ')
1274
1283
 
1275
- const containerClass = `flex w-full flex-col items-center justify-center rounded-xl pt-6 relative ${
1276
- isDark ? 'bg-dark-3' : 'bg-blue-100'
1277
- } ${isAudio ? 'md:pt-5' : 'md:pt-8'}`
1284
+ const isPro =
1285
+ this.type === 'proMiningArticle' || this.type === 'proMiningOutlook'
1286
+
1287
+ const backgroundDefault = isPro ? 'bg-grey-100' : 'bg-blue-100'
1288
+ const backgroundClass = isDark ? 'bg-dark-3' : backgroundDefault
1278
1289
 
1279
- const borderClass = isDark ? 'border-dark-8' : 'border-blue-200'
1290
+ const containerClass = `flex w-full flex-col items-center justify-center rounded-xl md:pt-8 pt-6 relative ${backgroundClass}`
1291
+
1292
+ // const borderClass = isDark ? 'border-dark-8' : 'border-blue-200'
1280
1293
 
1281
1294
  return html`
1282
1295
  <div class="${wrapperBodyClass}">
1283
1296
  <div
1284
- class="flex flex-col justify-center items-center w-full max-w-screen-sm my-5 relative"
1297
+ class="flex flex-col justify-center items-center w-full max-w-screen-sm my-5 relative"
1285
1298
  >
1286
1299
  ${isEpaper || isAudio ? this.topNavigator(this.type) : nothing}
1287
1300
  <div class="${containerClass}">
1288
- ${this.headerSection(
1289
- this.type,
1290
- this.paywallData?.informations?.title ?? ''
1291
- )}
1292
- ${this.descriptionSection(
1293
- this.paywallData?.informations?.description ?? []
1294
- )}
1295
- ${this.packagesSection(
1296
- this.paywallData?.packages ?? ({} as Packages)
1297
- )}
1298
- ${this.ctaPackages()}
1301
+ <div class="px-6 md:px-0 items-center flex flex-col w-full">
1302
+ ${this.headerSection(
1303
+ this.type,
1304
+ this.paywallData?.informations?.title ?? ''
1305
+ )}
1306
+ ${this.excerptSection(
1307
+ this.paywallData?.informations?.excerpt ?? ''
1308
+ )}
1309
+ ${this.packagesSection(
1310
+ this.paywallData?.packages ?? ({} as Packages)
1311
+ )}
1312
+ ${this.ctaPackages()}
1313
+ ${this.descriptionSection(
1314
+ this.paywallData?.informations?.description ?? []
1315
+ )}
1316
+ </div>
1299
1317
  ${!isLogin
1300
- ? html`
1301
- <div
1302
- class="border-b w-1/5 flex justify-center ${borderClass} ${isAudio
1303
- ? 'my-4 md:my-3'
1304
- : 'my-4'}"
1305
- ></div>
1306
- ${this.registrationSection(this.type)}
1307
- `
1318
+ ? html` ${this.registrationSection(this.type)} `
1308
1319
  : nothing}
1309
1320
  ${this.userAction()}
1310
1321
  </div>
@@ -21,6 +21,9 @@
21
21
  | `tracker_content_title` | `tracker_content_title` | | `string` | `''` |
22
22
  | `tracker_content_type` | `tracker_content_type` | | `string` | `''` |
23
23
  | `tracker_content_publisher` | `tracker_content_publisher` | | `string` | `''` |
24
+ | `tracker_content_published_date`| `tracker_content_published_date`| | `string` | `''` |
25
+ | `tracker_content_tags` | `tracker_content_tags` | | `string` | `''` |
26
+ | `tracker_content_variant` | `tracker_content_variant` | | `string` | `''` |
24
27
  | `tracker_epaper_edition` | `tracker_epaper_edition` | | `string` | `''` |
25
28
  | `tracker_metered_wall_balance` | `tracker_metered_wall_balance` | | `number` | `0` |
26
29
  | `tracker_metered_wall_type` | `tracker_metered_wall_type` | | `string` | `''` |