<s> from xierpa3 . toolbox . transformer import TX <EOL> from xierpa3 . themes . shop . shop import Shop <EOL> from xierpa3 . adapters import TextileFileAdapter <EOL> from xierpa3 . attributes import Em , Color , Perc <EOL> from xierpa3 . components import Logo , Menu , SocialMedia , Article , ArticleSideBar , MobileNavigation , Container , Header , Footer , Page , Documentation , ItemGroup , FeaturedByImage <EOL> class DbDAdapter ( TextileFileAdapter ) : <EOL> def getDescription ( self ) : <EOL> return self . newArticle ( text = u"""<STR_LIT>""" ) <EOL> def getKeyWords ( self ) : <EOL> return self . newArticle ( text = u"""<STR_LIT>""" ) <EOL> class DoingByDesign ( Shop ) : <EOL> u"""<STR_LIT>""" <EOL> C = Shop . C <EOL> TITLE = '<STR_LIT>' <EOL> SUBTITLE = '<STR_LIT>' <EOL> LOGO = '<STR_LIT>' <EOL> TEMPLATE_COURSES = '<STR_LIT>' <EOL> TEMPLATE_CATEGORY = '<STR_LIT>' <EOL> TEMPLATE_PRODUCTS = '<STR_LIT>' <EOL> URL_BACKGROUNDIMAGE = '<STR_LIT>' <EOL> URL_JAVASCRIPT = [ '<STR_LIT>' , '<STR_LIT>' ] <EOL> CSS_BODYFAMILY = '<STR_LIT>' <EOL> CSS_HEADFAMILY = '<STR_LIT>' <EOL> CSS_BODYSIZE = <NUM_LIT> <EOL> CSS_BODYLEADING = Em ( <NUM_LIT> ) <EOL> CSS_BGCOLOR = Color ( '<STR_LIT>' ) <EOL> CSS_FOOTERBGCOLOR = Color ( '<STR_LIT>' ) <EOL> CSS_ALINKCOLOR = Color ( '<STR_LIT>' ) <EOL> CSS_AVISITEDCOLOR = '<STR_LIT>' <EOL> CSS_AHOVERCOLOR = '<STR_LIT>' <EOL> CSS_ACTIVECOLOR = '<STR_LIT>' <EOL> MAXWIDTH = <NUM_LIT> <EOL> MINWIDTH = <NUM_LIT> <EOL> def baseStyle ( self ) : <EOL> s = self . newStyle ( ) <EOL> s . addStyle ( '<STR_LIT:body>' , fontfamily = self . CSS_BODYFAMILY , fontsize = self . CSS_BODYSIZE , <EOL> backgroundcolor = self . CSS_BGCOLOR , lineheight = self . CSS_BODYLEADING ) <EOL> s . addStyle ( '<STR_LIT>' , fontfamily = self . CSS_HEADFAMILY ) <EOL> s . addStyle ( '<STR_LIT>' , fontfamily = self . CSS_BODYFAMILY ) <EOL> s . addStyle ( '<STR_LIT>' , float = self . C . LEFT , width = Perc ( <NUM_LIT:100> ) ) <EOL> s . addStyle ( '<STR_LIT>' , color = self . CSS_ALINKCOLOR ) <EOL> s . addStyle ( '<STR_LIT>' , color = self . CSS_AVISITEDCOLOR ) <EOL> s . addStyle ( '<STR_LIT>' , color = self . CSS_AHOVERCOLOR ) <EOL> s . addStyle ( '<STR_LIT>' , color = self . CSS_ACTIVECOLOR ) <EOL> s . addStyle ( '<STR_LIT>' + self . C . CLASS_1COL , margin = Em ( <NUM_LIT:0.5> ) , float = self . C . LEFT , width = Perc ( <NUM_LIT> / <NUM_LIT:12> ) ) <EOL> s . addStyle ( '<STR_LIT>' + self . C . CLASS_2COL , margin = Em ( <NUM_LIT:0.5> ) , float = self . C . LEFT , width = Perc ( <NUM_LIT> * <NUM_LIT:2> / <NUM_LIT:12> ) ) <EOL> s . addStyle ( '<STR_LIT>' + self . C . CLASS_4COL , margin = Em ( <NUM_LIT:0.5> ) , float = self . C . LEFT , width = Perc ( <NUM_LIT:30> ) ) <EOL> s . addStyle ( '<STR_LIT>' + self . C . CLASS_8COL , margin = Em ( <NUM_LIT:0.5> ) , float = self . C . LEFT , width = Perc ( <NUM_LIT> * <NUM_LIT:8> / <NUM_LIT:12> ) ) <EOL> s . addStyle ( '<STR_LIT>' + self . C . CLASS_12COL , margin = Em ( <NUM_LIT:0.5> ) , float = self . C . LEFT , width = Perc ( <NUM_LIT:100> ) ) <EOL> s . addStyle ( '<STR_LIT>' + self . C . CLASS_LAST , marginright = Em ( <NUM_LIT:0> ) ) <EOL> s . addStyle ( '<STR_LIT>' , display = self . C . BLOCK ) <EOL> s . addStyle ( '<STR_LIT>' , display = self . C . BLOCK ) <EOL> s . addStyle ( '<STR_LIT>' , liststyletype = self . C . DECIMAL ) <EOL> return s <EOL> def baseComponents ( self ) : <EOL> logo = Logo ( ) <EOL> menu = Menu ( ) <EOL> socialmedia = SocialMedia ( twitterAccount = '<STR_LIT>' , facebookAccount = '<STR_LIT>' ) <EOL> header = Header ( components = ( logo , menu ) , mobileContainerDisplay = self . C . NONE , <EOL> doc_mobileContainerDisplay = u'<STR_LIT>' ) <EOL> mobileNavigation = MobileNavigation ( ) <EOL> featuredSideText = featuredByImage = featuredByText = featuredByTextList = featuredByImage100 = FeaturedByImage ( ) <EOL> BGCOLOR = Color ( '<STR_LIT>' ) <EOL> featuredImages = FeaturedByImage ( class_ = '<STR_LIT>' , <EOL> components = ( featuredByImage , featuredSideText ) , <EOL> containerBackgroundColor = BGCOLOR ) <EOL> BGCOLOR = Color ( '<STR_LIT>' ) <EOL> featuredTexts = FeaturedByImage ( class_ = '<STR_LIT>' , <EOL> components = ( featuredByText , featuredByTextList ) , <EOL> containerBackgroundColor = BGCOLOR ) <EOL> footer = Footer ( components = ( menu , ) , containerBackgroundColor = self . CSS_FOOTERBGCOLOR ) <EOL> documentation = Documentation ( ) <EOL> featuredByTextList = FeaturedByImage ( ) <EOL> article = Container ( class_ = self . C . CLASS_ARTICLE , <EOL> containerBackgroundImage = self . URL_BACKGROUNDIMAGE , containerBackgroundRepeat = self . C . REPEAT , <EOL> components = ( Article ( ) , socialmedia , ArticleSideBar ( ) , featuredByTextList ) ) <EOL> thumbnails = ItemGroup ( components = ( featuredByImage100 , ) ) <EOL> from xierpa3 . sites import doingbydesign <EOL> articleRoot = TX . module2Path ( doingbydesign ) + '<STR_LIT>' <EOL> adapter = DbDAdapter ( articleRoot ) <EOL> homePage = Page ( name = self . C . TEMPLATE_INDEX , <EOL> components = featuredSideText , <EOL> css = self . C . URL_CSS , fonts = self . C . URL_FONTS , js = self . URL_JAVASCRIPT , <EOL> favicon = self . C . URL_FAVICON , adapter = adapter ) <EOL> articlePage = Page ( name = self . C . TEMPLATE_ARTICLE , <EOL> components = ( mobileNavigation , header , article , footer ) , <EOL> css = self . C . URL_CSS , fonts = self . C . URL_FONTS , js = self . URL_JAVASCRIPT , <EOL> favicon = self . C . URL_FAVICON , adapter = adapter ) <EOL> thumbnailPage = Page ( name = self . TEMPLATE_COURSES , <EOL> components = ( mobileNavigation , header , featuredImages , footer ) , <EOL> css = self . C . URL_CSS , fonts = self . C . URL_FONTS , js = self . URL_JAVASCRIPT , <EOL> favicon = self . C . URL_FAVICON , adapter = adapter ) <EOL> productsPage = Page ( name = self . TEMPLATE_PRODUCTS , <EOL> components = ( mobileNavigation , header , thumbnails , footer ) , <EOL> css = self . C . URL_CSS , fonts = self . C . URL_FONTS , js = self . URL_JAVASCRIPT , <EOL> favicon = self . C . URL_FAVICON , adapter = adapter ) <EOL> categoryPage = Page ( name = self . TEMPLATE_CATEGORY , <EOL> components = ( mobileNavigation , header , footer ) , <EOL> css = self . C . URL_CSS , fonts = self . C . URL_FONTS , js = self . URL_JAVASCRIPT , <EOL> favicon = self . C . URL_FAVICON , adapter = adapter ) <EOL> documentationPage = Page ( name = self . C . TEMPLATE_DOCUMENTATION , <EOL> components = ( mobileNavigation , header , documentation , footer ) , <EOL> css = self . C . URL_CSS , fonts = self . C . URL_FONTS , js = self . URL_JAVASCRIPT , <EOL> favicon = self . C . URL_FAVICON , adapter = adapter ) <EOL> return [ homePage , articlePage , productsPage , thumbnailPage , categoryPage , documentationPage ] </s>
