jekyll_patternbot 0.12.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 (116) hide show
  1. checksums.yaml +7 -0
  2. data/.editorconfig +12 -0
  3. data/.gitattributes +13 -0
  4. data/.gitignore +73 -0
  5. data/CHANGELOG.md +68 -0
  6. data/Gemfile +16 -0
  7. data/LICENSE.txt +21 -0
  8. data/README.md +39 -0
  9. data/Rakefile +1 -0
  10. data/_config.yml +54 -0
  11. data/_data/locales/en-ca.yml +5 -0
  12. data/_includes/patternbot_icons.html +38 -0
  13. data/_includes/patternbot_pattern_brand_color_swatches.html +48 -0
  14. data/_includes/patternbot_pattern_brand_typeface.html +32 -0
  15. data/_includes/patternbot_pattern_brand_typeface_weight.html +15 -0
  16. data/_includes/patternbot_pattern_copy_script.html +22 -0
  17. data/_includes/patternbot_patternlib_pattern.html +241 -0
  18. data/_layouts/patternbot_pattern_internal.html +94 -0
  19. data/_layouts/patternbot_pattern_lib.html +214 -0
  20. data/_layouts/patternbot_pattern_user.html +27 -0
  21. data/_patterns/brand/colors.html +23 -0
  22. data/_patterns/brand/config.yml +22 -0
  23. data/_patterns/brand/logos.html +43 -0
  24. data/_patterns/brand/typefaces.html +18 -0
  25. data/_patterns/grid/config.yml +14 -0
  26. data/_patterns/grid/grid-sizes.html +47 -0
  27. data/_patterns/icons/config.yml +13 -0
  28. data/_patterns/icons/icons.html +91 -0
  29. data/_patterns/modules/config.yml +32 -0
  30. data/_patterns/modules/embed.html +23 -0
  31. data/_patterns/modules/list-groups.html +21 -0
  32. data/_patterns/modules/media-objects.html +16 -0
  33. data/_patterns/typography/config.yml +55 -0
  34. data/_patterns/typography/emphasis-and-edits.html +80 -0
  35. data/_patterns/typography/font-sizes.html +90 -0
  36. data/_patterns/typography/headings.html +31 -0
  37. data/_patterns/typography/horizontal-spacing.html +46 -0
  38. data/_patterns/typography/links.html +11 -0
  39. data/_patterns/typography/lists.html +43 -0
  40. data/_patterns/typography/quotations.html +17 -0
  41. data/_patterns/typography/size-adjustments.html +20 -0
  42. data/_patterns/typography/typesetting.html +32 -0
  43. data/_patterns/typography/vertical-spacing.html +55 -0
  44. data/_patterns/utilities/config.yml +11 -0
  45. data/_patterns/utilities/utilities.html +18 -0
  46. data/_plugins/jekyll_patternbot/config.rb +19 -0
  47. data/_plugins/jekyll_patternbot/filters/color.rb +87 -0
  48. data/_plugins/jekyll_patternbot/filters/number.rb +11 -0
  49. data/_plugins/jekyll_patternbot/filters/pattern.rb +15 -0
  50. data/_plugins/jekyll_patternbot/filters/text.rb +33 -0
  51. data/_plugins/jekyll_patternbot/finders/finder.rb +34 -0
  52. data/_plugins/jekyll_patternbot/finders/icons.rb +25 -0
  53. data/_plugins/jekyll_patternbot/finders/logos.rb +26 -0
  54. data/_plugins/jekyll_patternbot/finders/patterns.rb +69 -0
  55. data/_plugins/jekyll_patternbot/finders/sample_pages.rb +18 -0
  56. data/_plugins/jekyll_patternbot/generators/internal_patterns.rb +56 -0
  57. data/_plugins/jekyll_patternbot/generators/pattern_lib.rb +27 -0
  58. data/_plugins/jekyll_patternbot/generators/user_patterns.rb +57 -0
  59. data/_plugins/jekyll_patternbot/helpers/color.rb +26 -0
  60. data/_plugins/jekyll_patternbot/helpers/file.rb +17 -0
  61. data/_plugins/jekyll_patternbot/helpers/jekyll.rb +60 -0
  62. data/_plugins/jekyll_patternbot/helpers/pattern.rb +36 -0
  63. data/_plugins/jekyll_patternbot/hooks/pattern_lib.rb +57 -0
  64. data/_plugins/jekyll_patternbot/loggers/patternbot.rb +24 -0
  65. data/_plugins/jekyll_patternbot/parsers/css_color.rb +54 -0
  66. data/_plugins/jekyll_patternbot/parsers/css_font.rb +109 -0
  67. data/_plugins/jekyll_patternbot/parsers/css_utility.rb +27 -0
  68. data/_plugins/jekyll_patternbot/parsers/gridifier.rb +22 -0
  69. data/_plugins/jekyll_patternbot/parsers/icons.rb +27 -0
  70. data/_plugins/jekyll_patternbot/parsers/modulifier.rb +10 -0
  71. data/_plugins/jekyll_patternbot/parsers/theme.rb +39 -0
  72. data/_plugins/jekyll_patternbot/parsers/typografier.rb +21 -0
  73. data/_plugins/jekyll_patternbot/parsers/web_dev_tool.rb +41 -0
  74. data/_plugins/jekyll_patternbot/processors/brand.rb +22 -0
  75. data/_plugins/jekyll_patternbot/processors/modules.rb +35 -0
  76. data/_plugins/jekyll_patternbot/tags/pattern.rb +19 -0
  77. data/_plugins/jekyll_patternbot/tags/pattern_css.rb +27 -0
  78. data/_plugins/jekyll_patternbot/tags/pattern_js.rb +27 -0
  79. data/_plugins/jekyll_patternbot.rb +55 -0
  80. data/_sass/.gitignore +0 -0
  81. data/assets/.gitignore +0 -0
  82. data/assets/_patternbot/common/common.css +223 -0
  83. data/assets/_patternbot/common/common.min.css +1 -0
  84. data/assets/_patternbot/common/gridifier.css +1175 -0
  85. data/assets/_patternbot/common/gridifier.min.css +1 -0
  86. data/assets/_patternbot/common/modulifier.css +539 -0
  87. data/assets/_patternbot/common/modulifier.min.css +1 -0
  88. data/assets/_patternbot/common/typografier.css +1787 -0
  89. data/assets/_patternbot/common/typografier.min.css +1 -0
  90. data/assets/_patternbot/images/placeholder-16by9.svg +1 -0
  91. data/assets/_patternbot/images/placeholder-1by1.svg +1 -0
  92. data/assets/_patternbot/patterns/brand/brand.css +79 -0
  93. data/assets/_patternbot/patterns/brand/brand.min.css +1 -0
  94. data/assets/_patternbot/patterns/grid/grid.css +27 -0
  95. data/assets/_patternbot/patterns/grid/grid.min.css +1 -0
  96. data/assets/_patternbot/patterns/icons/icons.css +41 -0
  97. data/assets/_patternbot/patterns/icons/icons.min.css +1 -0
  98. data/assets/_patternbot/patterns/modules/modules.css +4 -0
  99. data/assets/_patternbot/patterns/modules/modules.min.css +1 -0
  100. data/assets/_patternbot/patterns/typography/typography.css +11 -0
  101. data/assets/_patternbot/patterns/typography/typography.min.css +1 -0
  102. data/assets/_patternbot/patterns/utilities/utilities.css +4 -0
  103. data/assets/_patternbot/patterns/utilities/utilities.min.css +1 -0
  104. data/assets/_patternbot/ui/gridifier.css +1175 -0
  105. data/assets/_patternbot/ui/main.css +513 -0
  106. data/assets/_patternbot/ui/main.js +301 -0
  107. data/assets/_patternbot/ui/modulifier.css +725 -0
  108. data/assets/_patternbot/ui/pattern-lib.css +4 -0
  109. data/assets/_patternbot/ui/pattern-lib.min.css +1 -0
  110. data/assets/_patternbot/ui/pattern-lib.min.js +1 -0
  111. data/assets/_patternbot/ui/typografier.css +1787 -0
  112. data/jekyll_patternbot.gemspec +34 -0
  113. data/package.json +35 -0
  114. data/version.rb +3 -0
  115. data/yarn.lock +2783 -0
  116. metadata +312 -0
@@ -0,0 +1,27 @@
1
+ module JekyllPatternbot
2
+ class CSSUtilityParser
3
+
4
+ def self.parse(filepath)
5
+ return false unless File.file? filepath
6
+ utilities = []
7
+ comment_match = false
8
+ File.open(filepath).each do |line|
9
+ unless comment_match
10
+ comment_match = line.strip.match Regexp.new "\\/\\*\s*#{Config['patternbot']['css']['utility_tag'].strip}\s+(?<description>[^\\*]*)\s*\\*\\/"
11
+ end
12
+ if comment_match
13
+ class_match = line.strip.match /\.[\w\d\-\_]+/
14
+ if class_match
15
+ utilities.push({
16
+ :class => class_match[0].strip,
17
+ :description => comment_match[:description].strip,
18
+ })
19
+ comment_match = false
20
+ end
21
+ end
22
+ end
23
+ utilities
24
+ end
25
+
26
+ end
27
+ end
@@ -0,0 +1,22 @@
1
+ module JekyllPatternbot
2
+ class GridifierParser < WebDevToolParser
3
+
4
+ def settings
5
+ grid_settings = []
6
+ url_info = extract_url_info
7
+
8
+ return nil unless url_info
9
+
10
+ url_info.split(/\;/).each do |mq_string|
11
+ mq = {}
12
+ mq[:prefix], mq[:columns], mq[:mq] = mq_string.split(/\,/)
13
+ mq[:columns] = mq[:columns].to_i
14
+ mq[:mq] = mq[:mq].to_f
15
+ grid_settings.push(mq)
16
+ end
17
+
18
+ grid_settings
19
+ end
20
+
21
+ end
22
+ end
@@ -0,0 +1,27 @@
1
+ module JekyllPatternbot
2
+ class IconsParser
3
+
4
+ def initialize(config, icon_files)
5
+ @config = config
6
+ @icon_files = icon_files
7
+ end
8
+
9
+ def filepath(filename)
10
+ File.expand_path filename, @config['source']
11
+ end
12
+
13
+ def symbols(data)
14
+ matches = data.scan /<symbol[^>]*id\s*=\s*"([^"]+)"/
15
+ matches.flatten
16
+ end
17
+
18
+ def info
19
+ for file in @icon_files
20
+ data = File.read filepath file[:filename]
21
+ file[:icons] = symbols data
22
+ end
23
+ @icon_files
24
+ end
25
+
26
+ end
27
+ end
@@ -0,0 +1,10 @@
1
+ module JekyllPatternbot
2
+ class ModulifierParser < WebDevToolParser
3
+
4
+ def settings
5
+ url_info = extract_url_info
6
+ url_info.split(/\;/) if url_info
7
+ end
8
+
9
+ end
10
+ end
@@ -0,0 +1,39 @@
1
+ module JekyllPatternbot
2
+ class ThemeParser
3
+
4
+ def initialize(filename)
5
+ @filename = filename
6
+ @filepath = File.expand_path filename, Config['patternbot']['css']['source']
7
+ end
8
+
9
+ def exists?
10
+ File.file? @filepath
11
+ end
12
+
13
+ def data
14
+ if @data.nil?
15
+ raw_data = File.read(@filepath)
16
+ parser = CssParser::Parser.new
17
+ parser.load_string!(raw_data)
18
+ css = parser.to_h
19
+
20
+ if css.key?('all') and css['all'].key?(':root')
21
+ @data = css['all'][':root']
22
+ end
23
+ end
24
+
25
+ @data
26
+ end
27
+
28
+ def info
29
+ {
30
+ :filename => @filename,
31
+ :filepath => @filepath,
32
+ :colors => data ? CSSColorParser.parse(data) : {},
33
+ :fonts => data ? CSSFontParser.parse(Config['patternbot']['font_url'], data) : {},
34
+ :utilities => CSSUtilityParser.parse(@filepath),
35
+ }
36
+ end
37
+
38
+ end
39
+ end
@@ -0,0 +1,21 @@
1
+ module JekyllPatternbot
2
+ class TypografierParser < WebDevToolParser
3
+
4
+ def settings
5
+ type_settings = []
6
+ url_info = extract_url_info
7
+
8
+ return nil unless url_info
9
+
10
+ url_info.split(/\;/).each do |mq_string|
11
+ mq = {}
12
+ mq[:mq], mq[:font_size], mq[:line_height], mq[:scale] = mq_string.split(/\,/)
13
+ mq = Hash[mq.map {|k, v| [k, v.to_f] }]
14
+ type_settings.push(mq)
15
+ end
16
+
17
+ type_settings
18
+ end
19
+
20
+ end
21
+ end
@@ -0,0 +1,41 @@
1
+ module JekyllPatternbot
2
+ class WebDevToolParser
3
+
4
+ def initialize(filename)
5
+ @filename = filename
6
+ @filepath = File.expand_path filename, Config['patternbot']['css']['source']
7
+ end
8
+
9
+ def exists?
10
+ File.file? @filepath
11
+ end
12
+
13
+ def data
14
+ if @data.nil? and File.file? @filepath
15
+ @data = File.read(@filepath)
16
+ @url_matches = @data.match(/https:\/\/(?<tool>modulifier|gridifier|typografier)\.web-dev\.tools\/#(?<url>[^\s]+)/)
17
+ @url = @url_matches[0]
18
+ end
19
+ @data
20
+ end
21
+
22
+ def extract_url_info
23
+ @url_matches[:url] if @url_matches
24
+ end
25
+
26
+ def settings
27
+ extract_url_info
28
+ end
29
+
30
+ def info
31
+ data
32
+ {
33
+ :filename => @filename,
34
+ :filepath => @filepath,
35
+ :url => @url,
36
+ :settings => settings,
37
+ }
38
+ end
39
+
40
+ end
41
+ end
@@ -0,0 +1,22 @@
1
+ module JekyllPatternbot
2
+ class BrandProcessor
3
+
4
+ def remove_colors
5
+ unless PatternbotData[:css].key? :theme and PatternbotData[:css][:theme].key? :colors
6
+ PatternbotData[:patterns][:internal]['brand'][:config]['patterns'].delete 'colors'
7
+ end
8
+ end
9
+
10
+ def remove_typefaces
11
+ unless PatternbotData[:css].key? :theme and PatternbotData[:css][:theme].key? :fonts
12
+ PatternbotData[:patterns][:internal]['brand'][:config]['patterns'].delete 'typefaces'
13
+ end
14
+ end
15
+
16
+ def process()
17
+ remove_colors
18
+ remove_typefaces
19
+ end
20
+
21
+ end
22
+ end
@@ -0,0 +1,35 @@
1
+ module JekyllPatternbot
2
+ class ModulesProcessor
3
+
4
+ def remove_embed
5
+ unless (PatternbotData[:css].key? :modulifier and
6
+ PatternbotData[:css][:modulifier].key? :settings and
7
+ PatternbotData[:css][:modulifier][:settings].include? 'embed')
8
+ PatternbotData[:patterns][:internal]['modules'][:config]['patterns'].delete 'embed'
9
+ end
10
+ end
11
+
12
+ def remove_media_objects
13
+ unless (PatternbotData[:css].key? :modulifier and
14
+ PatternbotData[:css][:modulifier].key? :settings and
15
+ PatternbotData[:css][:modulifier][:settings].include? 'media-object')
16
+ PatternbotData[:patterns][:internal]['modules'][:config]['patterns'].delete 'media-objects'
17
+ end
18
+ end
19
+
20
+ def remove_list_group
21
+ unless (PatternbotData[:css].key? :modulifier and
22
+ PatternbotData[:css][:modulifier].key? :settings and
23
+ PatternbotData[:css][:modulifier][:settings].include? 'list-group')
24
+ PatternbotData[:patterns][:internal]['modules'][:config]['patterns'].delete 'list-groups'
25
+ end
26
+ end
27
+
28
+ def process()
29
+ remove_embed
30
+ remove_media_objects
31
+ remove_list_group
32
+ end
33
+
34
+ end
35
+ end
@@ -0,0 +1,19 @@
1
+ module JekyllPatternbot
2
+ class PatternTag < Jekyll::Tags::IncludeTag
3
+
4
+ def tag_includes_dirs(context)
5
+ [File.join(context.registers[:site].config['source'], Config['patternbot']['source'])].freeze
6
+ end
7
+
8
+ def locate_include_file(context, file, safe)
9
+ if file.end_with? '.html'
10
+ super context, file, safe
11
+ else
12
+ super context, "#{file}.html", safe
13
+ end
14
+ end
15
+
16
+ end
17
+ end
18
+
19
+ Liquid::Template.register_tag('pattern', JekyllPatternbot::PatternTag)
@@ -0,0 +1,27 @@
1
+ module JekyllPatternbot
2
+
3
+ module PatternCSS
4
+
5
+ def self.css_files
6
+ FileHelper.list_files_with_ext Config['patternbot']['source'], 'css'
7
+ end
8
+
9
+ def self.css
10
+ css = {}
11
+ css_files.each do |file|
12
+ css[FileHelper.strip file] = File.read(file)
13
+ end
14
+ css
15
+ end
16
+
17
+ end
18
+
19
+ class PatternCSSTag < Liquid::Tag
20
+ def render(context)
21
+ PatternCSS.css.map { |k, v| v } .join("\n")
22
+ end
23
+ end
24
+
25
+ end
26
+
27
+ Liquid::Template.register_tag('pattern_css', JekyllPatternbot::PatternCSSTag)
@@ -0,0 +1,27 @@
1
+ module JekyllPatternbot
2
+
3
+ module PatternJS
4
+
5
+ def self.js_files
6
+ FileHelper.list_files_with_ext Config['patternbot']['source'], 'js'
7
+ end
8
+
9
+ def self.js
10
+ js = {}
11
+ js_files.each do |file|
12
+ js[FileHelper.strip file] = File.read(file)
13
+ end
14
+ js
15
+ end
16
+
17
+ end
18
+
19
+ class PatternJSTag < Liquid::Tag
20
+ def render(context)
21
+ PatternJS.js.map { |k, v| v } .join("\n")
22
+ end
23
+ end
24
+
25
+ end
26
+
27
+ Liquid::Template.register_tag('pattern_js', JekyllPatternbot::PatternJSTag)
@@ -0,0 +1,55 @@
1
+ # frozen_string_literal: true
2
+
3
+ require 'open-uri'
4
+ require 'babosa'
5
+ require 'deep_merge'
6
+ require 'yaml'
7
+ require 'json'
8
+ require 'unicode_titlecase'
9
+ require 'css_parser'
10
+ require 'color_contrast_calc'
11
+
12
+ module JekyllPatternbot
13
+ require 'jekyll_patternbot/config'
14
+
15
+ require 'jekyll_patternbot/loggers/patternbot'
16
+
17
+ require 'jekyll_patternbot/helpers/file'
18
+ require 'jekyll_patternbot/helpers/color'
19
+ require 'jekyll_patternbot/helpers/jekyll'
20
+ require 'jekyll_patternbot/helpers/pattern'
21
+
22
+ require 'jekyll_patternbot/parsers/web_dev_tool'
23
+ require 'jekyll_patternbot/parsers/modulifier'
24
+ require 'jekyll_patternbot/parsers/gridifier'
25
+ require 'jekyll_patternbot/parsers/typografier'
26
+ require 'jekyll_patternbot/parsers/css_color'
27
+ require 'jekyll_patternbot/parsers/css_font'
28
+ require 'jekyll_patternbot/parsers/css_utility'
29
+ require 'jekyll_patternbot/parsers/theme'
30
+ require 'jekyll_patternbot/parsers/icons'
31
+
32
+ require 'jekyll_patternbot/finders/finder'
33
+ require 'jekyll_patternbot/finders/logos'
34
+ require 'jekyll_patternbot/finders/icons'
35
+ require 'jekyll_patternbot/finders/patterns'
36
+ require 'jekyll_patternbot/finders/sample_pages'
37
+
38
+ require 'jekyll_patternbot/processors/brand'
39
+ require 'jekyll_patternbot/processors/modules'
40
+
41
+ require 'jekyll_patternbot/hooks/pattern_lib'
42
+
43
+ require 'jekyll_patternbot/tags/pattern'
44
+ require 'jekyll_patternbot/tags/pattern_css'
45
+ require 'jekyll_patternbot/tags/pattern_js'
46
+
47
+ require 'jekyll_patternbot/filters/text'
48
+ require 'jekyll_patternbot/filters/color'
49
+ require 'jekyll_patternbot/filters/number'
50
+ require 'jekyll_patternbot/filters/pattern'
51
+
52
+ require 'jekyll_patternbot/generators/internal_patterns'
53
+ require 'jekyll_patternbot/generators/user_patterns'
54
+ require 'jekyll_patternbot/generators/pattern_lib'
55
+ end
data/_sass/.gitignore ADDED
File without changes
data/assets/.gitignore ADDED
File without changes
@@ -0,0 +1,223 @@
1
+ :root {
2
+ --color-patternbot-primary: rgba(var(--color-patternbot-interface), var(--color-patternbot-interface), var(--color-patternbot-interface), .9);
3
+ --color-patternbot-opposite: rgba(var(--color-patternbot-interface-opposite), var(--color-patternbot-interface-opposite), var(--color-patternbot-interface-opposite), .9);
4
+ --color-patternbot-interface-background: #fff;
5
+
6
+ --font-patternbot-primary: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
7
+ --font-patternbot-code: "Source Code Pro", monospace;
8
+ }
9
+
10
+ html {
11
+ font-family: var(--font-patternbot-primary);
12
+ }
13
+
14
+ .patternbot-no-wrap {
15
+ white-space: nowrap;
16
+ }
17
+
18
+ .patternbot-list-group {
19
+ background-color: transparent;
20
+ text-align: left;
21
+ }
22
+
23
+ .patternbot-list-group > li::before {
24
+ content: "";
25
+ display: none;
26
+ }
27
+
28
+ .patternbot-font-primary {
29
+ font-family: var(--font-patternbot-primary);
30
+ }
31
+
32
+ .patternbot-color-body {
33
+ color: var(--color-patternbot-primary);
34
+ }
35
+
36
+ .patternbot-max-length {
37
+ margin-left: 0;
38
+ margin-right: 0;
39
+ }
40
+
41
+ code,
42
+ pre {
43
+ display: block;
44
+ margin: 0;
45
+ overflow-x: hidden;
46
+
47
+ color: var(--color-patternbot-primary);
48
+ font-family: var(--font-patternbot-code);
49
+ font-size: 14px;
50
+ font-style: normal;
51
+ font-weight: normal;
52
+ line-height: 2;
53
+ }
54
+
55
+ code {
56
+ padding: 0 .4em .15em;
57
+
58
+ background-color: rgba(var(--color-patternbot-interface), var(--color-patternbot-interface), var(--color-patternbot-interface), .05);
59
+ border: 1px solid transparent;
60
+ border-color: rgba(var(--color-patternbot-interface), var(--color-patternbot-interface), var(--color-patternbot-interface), .05);
61
+ border-radius: 4px;
62
+ }
63
+
64
+ .patternbot-hr {
65
+ border-width: 1px;
66
+ border-color: rgba(var(--color-patternbot-interface), var(--color-patternbot-interface), var(--color-patternbot-interface), .1);
67
+ }
68
+
69
+ .patternbot-hr:last-child,
70
+ .patternbot-hr:last-of-type:not(:first-child) {
71
+ display: none;
72
+ }
73
+
74
+ .patternbot-code-invisible {
75
+ background-color: transparent;
76
+ border-color: transparent;
77
+ }
78
+
79
+ .patternbot-pad-box {
80
+ background-color: var(--color-patternbot-interface-accent, --color-primary, rgba(var(--color-patternbot-interface), var(--color-patternbot-interface), var(--color-patternbot-interface)));
81
+ }
82
+
83
+ .patternbot-pad-box-inner {
84
+ overflow: hidden;
85
+
86
+ background-color: var(--color-patternbot-interface-background);
87
+ }
88
+
89
+ .patternbot-spacing-display {
90
+
91
+ }
92
+
93
+ .patternbot-spacing-display h2 {
94
+ color: var(--color-patternbot-primary);
95
+ line-height: 1.9;
96
+ font-family: var(--font-patternbot-primary);
97
+ font-size: 32px;
98
+ font-style: normal;
99
+ font-weight: bold;
100
+ }
101
+
102
+ .patternbot-mq-display-wrap {
103
+ max-width: 100%;
104
+ overflow-x: auto;
105
+ -webkit-overflow-scrolling: touch;
106
+ width: 100%;
107
+ }
108
+
109
+ .patternbot-mq-display-wrap,
110
+ .patternbot-mq-display-wrap * {
111
+ color: var(--color-patternbot-primary);
112
+ line-height: 2;
113
+ font-family: var(--font-patternbot-primary);
114
+ font-size: 14px;
115
+ font-style: normal;
116
+ font-weight: normal;
117
+ }
118
+
119
+ .patternbot-mq-display {
120
+ background-color: transparent;
121
+ overflow: hidden;
122
+ }
123
+
124
+ .patternbot-mq-display > li {
125
+ padding: 0;
126
+ }
127
+
128
+ .patternbot-mq-display > li:last-child {
129
+ padding-bottom: 6rem;
130
+ }
131
+
132
+ .patternbot-mq-inner {
133
+ min-height: 2rem;
134
+
135
+ background-color: var(--color-patternbot-interface-accent, --color-primary, rgba(var(--color-patternbot-interface), var(--color-patternbot-interface), var(--color-patternbot-interface), .1));
136
+ border-top: 2px solid var(--color-patternbot-interface-background);
137
+ }
138
+
139
+ .patternbot-mq-list {
140
+ min-width: 24em;
141
+ padding-top: 2.2rem;
142
+
143
+ border-left: 2px solid var(--color-patternbot-interface-accent, --color-primary, rgba(var(--color-patternbot-interface), var(--color-patternbot-interface), var(--color-patternbot-interface), .1));
144
+ }
145
+
146
+ .patternbot-mq-list > dt,
147
+ .patternbot-mq-list > dd {
148
+ padding: 0;
149
+
150
+ font-weight: normal;
151
+ font-style: normal;
152
+ font-size: inherit;
153
+ }
154
+
155
+ .patternbot-mq-list > dt {
156
+ width: 7em;
157
+ }
158
+
159
+ .patternbot-code-details {
160
+ margin: 0 0 .75em;
161
+ padding: 1.5em 0 0 0;
162
+
163
+ border-bottom: 1px solid rgba(var(--color-patternbot-interface), var(--color-patternbot-interface), var(--color-patternbot-interface), .05);
164
+
165
+ color: var(--color-patternbot-primary);
166
+ font-size: 14px;
167
+ line-height: 2;
168
+ text-align: left;
169
+ }
170
+
171
+ .patternbot-code-details * {
172
+ color: var(--color-patternbot-primary);
173
+ }
174
+
175
+ .patternbot-code-details-under {
176
+ padding-top: 0;
177
+
178
+ border: 0;
179
+ }
180
+
181
+ .patternbot-code-details-center {
182
+ text-align: center;
183
+ }
184
+
185
+ .patternbot-tool-btn {
186
+ display: flex;
187
+ left: 100%;
188
+ min-height: 1.4em;
189
+ min-width: 1.2em;
190
+ padding: 1px 2px 2px;
191
+ position: absolute;
192
+ top: 50%;
193
+ transform: translateY(-50%);
194
+
195
+ background-color: transparent;
196
+ border: 2px solid transparent;
197
+ border-radius: 4px;
198
+ cursor: pointer;
199
+ opacity: .4;
200
+ stroke: var(--color-patternbot-primary);
201
+
202
+ color: var(--color-patternbot-primary);
203
+ }
204
+
205
+ .patternbot-tool-btn * {
206
+ stroke: var(--color-patternbot-primary);
207
+ color: var(--color-patternbot-primary);
208
+ }
209
+
210
+ .patternbot-tool-btn:focus,
211
+ .patternbot-tool-btn:hover {
212
+ background-color: transparent;
213
+ border-color: transparent;
214
+ outline: none;
215
+ opacity: 1;
216
+ color: var(--color-patternbot-primary);
217
+ }
218
+
219
+ .patternbot-tool-btn:focus,
220
+ .patternbot-tool-btn:active,
221
+ .patternbot-tool-btn[aria-pressed="true"] {
222
+ border-color: var(--color-patternbot-primary);
223
+ }