
com.adobe.aemds.guide.utils.GuideThemeUtils.class Maven / Gradle / Ivy
???? 3?
?123
4567? 389 3: ;<5: = >? T@ TABCD
EFGH
1
IJ TK TL
MNBOPC
?QRSRT U
?V ?WXYZ[\
+1 ]
^_ 3`abcdcefghi
?jk
71
?lRmhbn <op
qr
?sRt 4uv
fw <xy Fzh{|
I1 F} <~
??????{
?? ?9??? T?? 4L T?? 4?
?? T??? F?h??
??? ???
f?
f? F? F?h? Fu???5? 3?u ??
?M
??
???
f?
f?v
????
????y
???????Y?? 3? 3?? 3???? ???
?4?
??
??
??????? ????
??
??
?????
?????Y??
?1
?????
?? 3? 3L ? ? ??? ?? ???5? ??5???
I?
??
?? ?? ?? 3?????Y?
?????
????
??
??
??
^?
?1
?
? 3
?
f
?
b
?1 ?
? ?
?r
?
? ? ? ??
InnerClasses logger Lorg/slf4j/Logger; ()V Code LineNumberTable LocalVariableTable this -Lcom/adobe/aemds/guide/utils/GuideThemeUtils; getConfiguredFormPagePath V(Lorg/apache/sling/api/resource/ResourceResolver;Ljava/lang/String;)Ljava/lang/String; resourceResolver 0Lorg/apache/sling/api/resource/ResourceResolver; themeContentPath Ljava/lang/String;
themeResource (Lorg/apache/sling/api/resource/Resource;
themeMetadata 2Lcom/adobe/aemds/guide/themes/model/ThemeMetadata;
StackMapTable getConfiguredFormPath themeContentNode Ljavax/jcr/Node; session Ljavax/jcr/Session; e Ljavax/jcr/RepositoryException;
formAssetPath?D getThemeClientlibCategory themeClientlibCategory getBaseClientlibCategory values [Ljavax/jcr/Value; clientlibLoc
clientlibNode baseClientlibCategory saveThemeCSS ?(Lcom/adobe/aemds/guide/themes/model/Theme;Lorg/apache/sling/api/resource/ResourceResolver;Lorg/apache/sling/resourcemerger/api/ResourceMergerService;)V cSSString theme *Lcom/adobe/aemds/guide/themes/model/Theme; resolver resourceMergerService ;Lorg/apache/sling/resourcemerger/api/ResourceMergerService;
Exceptions getThemeCSS ?(Lcom/adobe/aemds/guide/themes/model/Theme;Lorg/apache/sling/api/resource/ResourceResolver;Lorg/apache/sling/resourcemerger/api/ResourceMergerService;)Ljava/lang/String;
childResource breakpointInfo 3Lcom/adobe/aemds/guide/themes/model/BreakpointInfo; childResources Ljava/util/Iterator; defaultBreakpoint component .Lcom/adobe/aemds/guide/themes/model/Component; selectorMap Ljava/util/Map; themeCss themeFormBreakpointList Ljava/util/List; breakpoints
themeFormPath breakpointNodeResource sortedBreakpoints currentFormBreakpointList componentIterator LocalVariableTypeTable >Ljava/util/Iterator; 5Ljava/util/Map; ELjava/util/List; DLjava/util/Iterator; !"#9f$ containsDefaultBreakpoint (Ljava/util/List;)Z
breakpoint breakpointIterator ILjava/util/Iterator; Signature H(Ljava/util/List;)Z getComponentCssString ?(Lcom/adobe/aemds/guide/themes/model/Component;Lorg/apache/sling/api/resource/ResourceResolver;Ljava/util/List;Ljava/util/List;Ljava/util/Map;Lcom/adobe/aemds/guide/themes/model/ThemeMetadata;)Ljava/lang/String; currentBreakpointId breakpointId selector -Lcom/adobe/aemds/guide/themes/model/Selector; selectorProperties (Lorg/apache/sling/api/resource/ValueMap; selectorBreakpointIdSet Ljava/util/Set; additionalBreakpointListIterator additionalBreakpointList selectorIterator #Ljava/util/Set; CLjava/util/Iterator;y?%n&c(Lcom/adobe/aemds/guide/themes/model/Component;Lorg/apache/sling/api/resource/ResourceResolver;Ljava/util/List;Ljava/util/List;Ljava/util/Map;Lcom/adobe/aemds/guide/themes/model/ThemeMetadata;)Ljava/lang/String; addBreakpointToTheme h(Lcom/adobe/aemds/guide/themes/model/BreakpointInfo;Lcom/adobe/aemds/guide/themes/model/ThemeMetadata;)V breakpointResource themeBreakpointNode newBreakpointNode Ljava/lang/Exception;? getSelectorCssString ?(Lcom/adobe/aemds/guide/themes/model/BreakpointInfo;Lcom/adobe/aemds/guide/themes/model/Selector;Lorg/apache/sling/api/resource/ValueMap;Lorg/apache/sling/api/resource/ResourceResolver;Ljava/util/Map;Ljava/lang/String;)Ljava/lang/String; propertyValueCssString key value cssProperty valueMap cssSelector cssOverride beforeSelector
afterSelector addonCss inlinePrefix stateName maskedPropertiesSet Ljava/util/HashSet;
cssProperties [Ljava/lang/String; selectorPath propertyName propertiesIterator inlineClass selectorCss stylePropertyNames 'Ljava/util/HashSet; (Ljava/util/Iterator; $Ljava/util/List;g|(Lcom/adobe/aemds/guide/themes/model/BreakpointInfo;Lcom/adobe/aemds/guide/themes/model/Selector;Lorg/apache/sling/api/resource/ValueMap;Lorg/apache/sling/api/resource/ResourceResolver;Ljava/util/Map;Ljava/lang/String;)Ljava/lang/String;
saveInlineCSS x(Lorg/apache/sling/api/resource/Resource;Ljava/lang/String;Lorg/apache/sling/resourcemerger/api/ResourceMergerService;)V cssString
properties 2Lorg/apache/sling/api/resource/ModifiableValueMap; resource formPath resourceType breakpointInfoList
styleResource overridePath getAddonCSSString 8(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String; propertyKey propValue *Lorg/apache/sling/commons/json/JSONObject; cssSelectorString propertyKeys addOnCSSObject selectors selectorKeys -Lorg/apache/sling/commons/json/JSONException;?? getTargetResource R(Lorg/apache/sling/api/resource/Resource;)Lorg/apache/sling/api/resource/Resource; target getPseudoCSSString J(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String; selectorString pseudoElementString selectorValueBuilder Ljava/lang/StringBuilder; st Ljava/util/StringTokenizer;H? updateClientLibForTheme i(Lorg/apache/sling/api/resource/ResourceResolver;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V contentResource map txtMap currentTime Ljava/util/Calendar; cssTxtResource
clientLibName
clientLibPath clientLibCompletePath clientLibResource< sortBreakpoints "(Ljava/util/List;)Ljava/util/List; ?(Ljava/util/List;)Ljava/util/List; makeCssComment &(Ljava/lang/String;)Ljava/lang/String;
copyAssets ?(Lorg/apache/sling/api/resource/Resource;Lorg/apache/sling/api/resource/Resource;Lorg/apache/sling/api/resource/ResourceResolver;)V toResourcePath fromResourceAssetNode toResourceNode
imageResource imageResourceName imageResourcePath oldImageResourcePath imageNode children toResourceAssetNode toResourceAssetPath toResourceAsset fromResourceAssetPath fromResourceAsset !Ljavax/jcr/PathNotFoundException; fromResource
toResource??
copyStyles ?(Lorg/apache/sling/api/resource/Resource;Lorg/apache/sling/api/resource/Resource;Lorg/apache/sling/api/resource/ResourceResolver;Ljava/lang/String;)V fromResourceStyleNode fromResourcePath fromResourceStylePath toResourceStylePath fromResourceStyle toResourceStyle toResourcePropertyMap fromResourcePropertyMap 4Lorg/apache/sling/api/resource/PersistenceException; cssClass?? getCssPropertyValue K(Ljava/lang/String;Ljava/lang/String;Ljava/util/HashSet;)Ljava/lang/String; property _(Ljava/lang/String;Ljava/lang/String;Ljava/util/HashSet;)Ljava/lang/String; getClientLibCategory <(Lorg/apache/sling/api/resource/Resource;)Ljava/lang/String; clientLib 3Lcom/adobe/aemds/guide/themes/model/ThemeClientLib; category getClientLibPath path getThemeClientLib ](Lorg/apache/sling/api/resource/Resource;)Lcom/adobe/aemds/guide/themes/model/ThemeClientLib;
themeNodeName
themeMetaData? getWebFontConfig getCommonClientLibName themeContentResource themeMetadataResource metadata
targetSpec getClientLibNames ~(Lorg/apache/sling/api/resource/Resource;Ljava/lang/String;Ljava/lang/String;)Lcom/adobe/aemds/guide/utils/ThemeClientLibData; formResource
themeOverride pageFallbackClientlib themeClientLibName commonClientLibName
clientLibData 0Lcom/adobe/aemds/guide/utils/ThemeClientLibData; isResourceTheme +(Lorg/apache/sling/api/resource/Resource;)Z Z generateSelectorString K(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Boolean;)Ljava/lang/String; i I className makeDescendantSelector Ljava/lang/Boolean;
selectorArray addTypekitConfigurations ?(Lorg/apache/sling/commons/json/JSONArray;Lorg/apache/sling/api/resource/Resource;Lcom/adobe/aemds/guide/service/internal/TypekitConfigurationService;)V
configuration 2Lcom/adobe/aemds/guide/model/TypekitConfiguration; responseObject response )Lorg/apache/sling/commons/json/JSONArray; typekitConfigurationService DLcom/adobe/aemds/guide/service/internal/TypekitConfigurationService;
collection Ljava/util/Collection; iterator JLjava/util/Collection; HLjava/util/Iterator;'()
?(Lorg/apache/sling/commons/json/JSONArray;Lorg/apache/sling/api/resource/Resource;Lorg/apache/sling/api/resource/ResourceResolver;Lcom/adobe/aemds/guide/service/internal/TypekitConfigurationService;)V \(Lorg/apache/sling/commons/json/JSONArray;Lorg/apache/sling/api/resource/ResourceResolver;)V 0Lcom/day/cq/wcm/webservicesupport/Configuration;
configManager 7Lcom/day/cq/wcm/webservicesupport/ConfigurationManager; it FLjava/util/Iterator;
Deprecated RuntimeVisibleAnnotations Ljava/lang/Deprecated;
SourceFile GuideThemeUtils.java ? ? ,com/adobe/aemds/guide/service/GuideException Invalid user session. ?*!+, 0com/adobe/aemds/guide/themes/GuideThemeConstants-, 0com/adobe/aemds/guide/themes/model/ThemeMetadata./01 javax/jcr/Session2345 metadata/formRef63789:1 javax/jcr/RepositoryException ?; metadata/clientlibCategory metadata/clientlibRef java/lang/StringBuilder<= />?@1A1 dependenciesBCD*+ E1FGH1?? ? ? Unable to save the Theme CssIJK java/util/ArrayListLMNOPQRST$UVWX &org/apache/sling/api/resource/Resource 1com/adobe/aemds/guide/themes/model/BreakpointInfo#YZKL 8com/adobe/aemds/guide/themes/model/DefaultBreakpointInfo??[M ,com/adobe/aemds/guide/themes/model/Component\1 cq:themeConfig]^_RS`1a1 defaultbZcM +com/adobe/aemds/guide/themes/model/SelectordefV java/util/HashSetghi1no%jZkZghlm javax/jcr/Node *com/adobe/aemds/guide/utils/GuideConstants nt:unstructuredno titlepq widthrstuvpw java/lang/Exception !Unable to add breakpoint to themexyzv @media (max-width : <{ px){
java/lang/String|} #~????????& /states/l,?e?Z???
{
~????? afterPseudoElement ::after?? beforePseudoElement ::before?? : ;
}
,CSS selector string not found for resource: J* 4CSS selector information not found for selector Id: ???1 style?1 cq:styleConfig 0org/apache/sling/api/resource/ModifiableValueMap cssStyle?? (org/apache/sling/commons/json/JSONObject???T:? {
+org/apache/sling/commons/json/JSONException Unable to parse addonCss object|? java/util/StringTokenizer , ???V?X css/theme.css/jcr:content jcr:data css.txt/jcr:content??? #com/day/cq/commons/jcr/JcrConstants jcr:lastModified 'Unable to find clientLib at location {}J? -com/adobe/aemds/guide/utils/GuideThemeUtils$1??? /* */ assets????T?3?*? ? javax/jcr/PathNotFoundException Error in copying StyleAssetk} cq:cssClass??? ? 2org/apache/sling/api/resource/PersistenceException Error in copying StyleNode?????1>m &org/apache/sling/api/resource/ValueMap clientlibRef 1com/adobe/aemds/guide/themes/model/ThemeClientLib NTheme client library missing at {}. Falling back to the default client library?? webFontConfigRef fd:targetVersion 1.0??? guide.theme2.common.legacy620 guide.theme2.common????????? .com/adobe/aemds/guide/utils/ThemeClientLibData?*?* fd/fm/theme/render?3f????V . )??' 0com/adobe/aemds/guide/model/TypekitConfiguration text?1???1??(??$ 5com/day/cq/wcm/webservicesupport/ConfigurationManager /etc/cloudservices/typekit?? .com/day/cq/wcm/webservicesupport/Configuration?1 +com/adobe/aemds/guide/utils/GuideThemeUtils??? java/lang/Object (com/adobe/aemds/guide/themes/model/Theme .org/apache/sling/api/resource/ResourceResolver 9org/apache/sling/resourcemerger/api/ResourceMergerService java/util/List java/util/Iterator
java/util/Set
java/util/Map java/util/Collection 'org/apache/sling/commons/json/JSONArray Bcom/adobe/aemds/guide/service/internal/TypekitConfigurationService (Ljava/lang/String;)V resolve <(Ljava/lang/String;)Lorg/apache/sling/api/resource/Resource; getChild adaptTo %(Ljava/lang/Class;)Ljava/lang/Object; getFormPagePath ()Ljava/lang/String;
nodeExists (Ljava/lang/String;)Z getNode $(Ljava/lang/String;)Ljavax/jcr/Node; hasProperty getProperty ((Ljava/lang/String;)Ljavax/jcr/Property; javax/jcr/Property getString (Ljava/lang/Exception;)V append -(Ljava/lang/String;)Ljava/lang/StringBuilder; getParent ()Ljavax/jcr/Node; getName toString getValues ()[Ljavax/jcr/Value; javax/jcr/Value getThemeNodeName getMetadata 4()Lcom/adobe/aemds/guide/themes/model/ThemeMetadata; getClientlibRef org/slf4j/Logger error *(Ljava/lang/String;Ljava/lang/Throwable;)V getBreakpoints ()Ljava/util/List; &com/adobe/aemds/guide/utils/GuideUtils getFormBreakpointResource l(Lorg/apache/sling/api/resource/ResourceResolver;Ljava/lang/String;)Lorg/apache/sling/api/resource/Resource; getChildren ()Ljava/lang/Iterable; java/lang/Iterable ()Ljava/util/Iterator; hasNext ()Z next ()Ljava/lang/Object; add (Ljava/lang/Object;)Z
getComponents getComponentPath 4com/adobe/aemds/guide/utils/GuideStyleMigrationUtils getSelectorMap ?(Ljava/lang/String;Lorg/apache/sling/api/resource/ResourceResolver;Lorg/apache/sling/resourcemerger/api/ResourceMergerService;Ljava/lang/String;)Ljava/util/Map; getRawCss getId equals getSelectors getSelectorAllProperties *()Lorg/apache/sling/api/resource/ValueMap; isEmpty getBreakpointsIdSet ()Ljava/util/Set; getInlineClass contains remove getResource *()Lorg/apache/sling/api/resource/Resource; addNode 6(Ljava/lang/String;Ljava/lang/String;)Ljavax/jcr/Node; setProperty :(Ljava/lang/String;Ljava/lang/String;)Ljavax/jcr/Property; getMax ()Ljava/lang/Integer; java/lang/Integer intValue ()I )(Ljava/lang/String;J)Ljavax/jcr/Property; getStylePropertyNames $(Ljava/lang/String;)Ljava/util/List; size -(Ljava/lang/Object;)Ljava/lang/StringBuilder; get &(Ljava/lang/Object;)Ljava/lang/Object; indexOf (Ljava/lang/String;)I substring (I)Ljava/lang/String; getMaskedPropertiesSet 9(Ljava/lang/String;Ljava/lang/String;)Ljava/util/HashSet; getCssPropertiesList 6(Ljava/lang/String;Ljava/lang/String;)Ljava/util/List; toArray (([Ljava/lang/Object;)[Ljava/lang/Object; getValueMap containsKey java/lang/Boolean valueOf (Z)Ljava/lang/Boolean; (I)I (II)Ljava/lang/String; getResourceResolver 2()Lorg/apache/sling/api/resource/ResourceResolver; getResourceType getPath put 8(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
getJSONObject >(Ljava/lang/String;)Lorg/apache/sling/commons/json/JSONObject; keys 7(Ljava/lang/String;Ljava/lang/Class;)Ljava/lang/Object; '(Ljava/lang/String;Ljava/lang/String;)V hasMoreElements nextElement java/util/Calendar getInstance ()Ljava/util/Calendar; '(Ljava/lang/String;Ljava/lang/Object;)V java/util/Collections sort )(Ljava/util/List;Ljava/util/Comparator;)V com/day/cq/commons/jcr/JcrUtil copy D(Ljavax/jcr/Node;Ljavax/jcr/Node;Ljava/lang/String;)Ljavax/jcr/Node; listChildren
itemExists
removeItem save delete +(Lorg/apache/sling/api/resource/Resource;)V commit getCategory info &com/adobe/aemds/guide/common/FDVersion compare '(Ljava/lang/String;Ljava/lang/String;)I $org/apache/commons/lang3/StringUtils
isNotBlank (Ljava/lang/CharSequence;)Z getThemeResource setCommonClientLib setThemeClientLib isResourceType split '(Ljava/lang/String;)[Ljava/lang/String; booleanValue getConfigurationCollection @(Lorg/apache/sling/api/resource/Resource;)Ljava/util/Collection;
isNotEmpty name P(Ljava/lang/String;Ljava/lang/Object;)Lorg/apache/sling/commons/json/JSONObject; =(Ljava/lang/Object;)Lorg/apache/sling/commons/json/JSONArray; getConfigurations ((Ljava/lang/String;)Ljava/util/Iterator; getTitle org/slf4j/LoggerFactory getLogger %(Ljava/lang/Class;)Lorg/slf4j/Logger; ! ? ?
? ? ! ? ? ? / *? ? > ? ? 0*?
? Y? ?*+? M,? ?
? N-? ? H I K L ) M * 0 0
)
? ]*?
? Y? ?M*?
? N+? 1-+? ? '-+? :? ? ? ? M?
N? Y-? ?,? N Q 2 X Y [ ] ^ * _ 3 ` ? a N f Q d R e [ g > 3 2 R ] ] M ? ?B ? ]*?
? Y? ?M*?
? N+? 1-+? ? '-+? :? ? ? ? M?
N? Y-? ?,? N Q 2 r s v x y * z 3 { ? | N ? Q R ? [ ? > 3 2 R ] ] M ? ?B ? ? ?*?
? Y? ?M*?
? N+? ?-+? ? y-+? :? ? d? ? :-? Y? ? ? ? ? ? ? ? :? ? ? ? :2? ! M?
N? Y-? ?,? ? ? B ? ? ? ? ? * ? 3 ? ? ? O ? z ? ? ? ? ? ? ? ? ? ? ? ? ? \ ?
O Q z & 3 m ? ? ? ? ? ? ?B !" ? ? 6*+,? "N+*? # -*? $ ? % ? &? N? '(-? ) ? Y-? ?? *
? ? ? ? ? ? ? ! ? , ? 5 ? 4 # ! 6$% 6& 6'( `) *+ ? ? *N? +Y? ,:*? $ :? - :? :+? .:? B? / ? 0 : ? 1 ? * ? 2 ? 3:
4?
? 4:? 5 W???? 6? ? 7Y? 8: ? 5 W? 9: ? 9:
*? : ? ; :? 1 ? B? 2 ? <:? = +,>? ?:
? Y? -? +
? @? ? N???? Y? -? *? A ? ? N-? j ? ? ? ? ? &