nugem 0.8.0 → 0.8.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +18 -9
- data/README.md +6 -0
- data/exe/nugem +9 -0
- data/lib/nugem/cli/cli_gem.rb +2 -2
- data/lib/nugem/version.rb +1 -1
- data/nugem.gemspec +2 -2
- data/templates/common/LICENCE.txt.tt +21 -0
- data/templates/common/executable_scaffold/exe/%gem_name%.tt +5 -0
- data/templates/common/executable_scaffold/lib/%gem_name%/cli.rb.tt +13 -0
- data/templates/common/gem_scaffold/%gem_name%.gemspec.tt +58 -0
- data/templates/common/gem_scaffold/CHANGELOG.md.tt +2 -0
- data/templates/common/gem_scaffold/Gemfile.tt +56 -0
- data/templates/common/gem_scaffold/README.md.tt +62 -0
- data/templates/common/gem_scaffold/Rakefile.tt +51 -0
- data/templates/common/gem_scaffold/bin/attach +34 -0
- data/templates/common/gem_scaffold/bin/console.tt +10 -0
- data/templates/common/gem_scaffold/bin/rake +13 -0
- data/templates/common/gem_scaffold/bin/setup.tt +24 -0
- data/templates/common/gem_scaffold/lib/%gem_name%/version.rb.tt +3 -0
- data/templates/common/gem_scaffold/lib/%gem_name%.rb.tt +12 -0
- data/templates/common/gem_scaffold/test/%gem_name%_test.rb.tt +11 -0
- data/templates/common/gem_scaffold/test/test_helper.rb.tt +96 -0
- data/templates/jekyll/block_no_arg_scaffold/lib/%block_name%.rb.tt +23 -0
- data/templates/jekyll/block_scaffold/lib/%block_name%.rb.tt +50 -0
- data/templates/jekyll/common_scaffold/spec/%gem_name%_spec.rb.tt +13 -0
- data/templates/jekyll/common_scaffold/spec/spec_helper.rb +79 -0
- data/templates/jekyll/demo/demo/Gemfile.tt +21 -0
- data/templates/jekyll/demo/demo/_bin/debug +71 -0
- data/templates/jekyll/demo/demo/_config.yml.tt +48 -0
- data/templates/jekyll/demo/demo/_drafts/2022/2022-05-01-test2.html +15 -0
- data/templates/jekyll/demo/demo/_includes/block_tag_template_wrapper +9 -0
- data/templates/jekyll/demo/demo/_layouts/default.html.tt +67 -0
- data/templates/jekyll/demo/demo/_posts/2022/2022-01-02-redact-test.html +12 -0
- data/templates/jekyll/demo/demo/assets/css/style.css +218 -0
- data/templates/jekyll/demo/demo/assets/images/404-error.png +0 -0
- data/templates/jekyll/demo/demo/assets/images/404-error.webp +0 -0
- data/templates/jekyll/demo/demo/assets/images/favicon.png +0 -0
- data/templates/jekyll/demo/demo/assets/images/jekyll.png +0 -0
- data/templates/jekyll/demo/demo/assets/images/jekyll.webp +0 -0
- data/templates/jekyll/demo/demo/assets/js/clipboard.min.js +7 -0
- data/templates/jekyll/demo/demo/assets/js/jquery-3.4.1.min.js +2 -0
- data/templates/jekyll/demo/demo/blog/blogsByDate.html +22 -0
- data/templates/jekyll/demo/demo/blog/index.html +36 -0
- data/templates/jekyll/demo/demo/index.html.tt +5 -0
- data/templates/jekyll/filter_scaffold/lib/%filter_name%.rb.tt +30 -0
- data/templates/jekyll/generator_scaffold/lib/%generator_name%.rb.tt +34 -0
- data/templates/jekyll/hooks_scaffold/lib/dumpers.rb +172 -0
- data/templates/jekyll/hooks_scaffold/lib/hooks.rb.tt +238 -0
- data/templates/jekyll/tag_no_arg_scaffold/lib/%tag_name%.rb.tt +18 -0
- data/templates/jekyll/tag_scaffold/lib/%tag_name%.rb.tt +43 -0
- data/templates/rails/engine_scaffold/bin/rails.tt +15 -0
- data/templates/rails/engine_scaffold/config/routes.rb.tt +6 -0
- data/templates/rails/engine_scaffold/lib/%gem_name%/engine.rb.tt +7 -0
- data/templates/rails/engine_scaffold/test/integration/navigation_test.rb +7 -0
- data/templates/rails/mountable_scaffold/app/assets/javascripts/%gem_name%/application.js +13 -0
- data/templates/rails/mountable_scaffold/app/assets/stylesheets/%gem_name%/application.css +15 -0
- data/templates/rails/mountable_scaffold/app/controllers/%gem_name%/application_controller.rb.tt +5 -0
- data/templates/rails/mountable_scaffold/app/helpers/%gem_name%/application_helper.rb.tt +4 -0
- data/templates/rails/mountable_scaffold/app/views/layouts/%gem_name%/application.html.erb.tt +14 -0
- data/templates/rails/plugin_scaffold/test/dummy/README.rdoc +28 -0
- data/templates/rails/plugin_scaffold/test/dummy/Rakefile +6 -0
- data/templates/rails/plugin_scaffold/test/dummy/app/assets/javascripts/application.js +13 -0
- data/templates/rails/plugin_scaffold/test/dummy/app/controllers/application_controller.rb +7 -0
- data/templates/rails/plugin_scaffold/test/dummy/app/helpers/application_helper.rb +2 -0
- data/templates/rails/plugin_scaffold/test/dummy/app/mailers/application_mailer.rb +4 -0
- data/templates/rails/plugin_scaffold/test/dummy/app/views/layouts/application.html.erb +14 -0
- data/templates/rails/plugin_scaffold/test/dummy/app/views/layouts/mailer.html.erb +9 -0
- data/templates/rails/plugin_scaffold/test/dummy/app/views/layouts/mailer.text.erb +1 -0
- data/templates/rails/plugin_scaffold/test/dummy/bin/bundle +4 -0
- data/templates/rails/plugin_scaffold/test/dummy/bin/rails +5 -0
- data/templates/rails/plugin_scaffold/test/dummy/bin/rake +6 -0
- data/templates/rails/plugin_scaffold/test/dummy/bin/setup +30 -0
- data/templates/rails/plugin_scaffold/test/dummy/config/application.rb.tt +26 -0
- data/templates/rails/plugin_scaffold/test/dummy/config/boot.rb +5 -0
- data/templates/rails/plugin_scaffold/test/dummy/config/database.yml +25 -0
- data/templates/rails/plugin_scaffold/test/dummy/config/environment.rb +5 -0
- data/templates/rails/plugin_scaffold/test/dummy/config/environments/development.rb +41 -0
- data/templates/rails/plugin_scaffold/test/dummy/config/environments/production.rb +79 -0
- data/templates/rails/plugin_scaffold/test/dummy/config/environments/test.rb +42 -0
- data/templates/rails/plugin_scaffold/test/dummy/config/initializers/assets.rb +11 -0
- data/templates/rails/plugin_scaffold/test/dummy/config/initializers/backtrace_silencers.rb +7 -0
- data/templates/rails/plugin_scaffold/test/dummy/config/initializers/cookies_serializer.rb +3 -0
- data/templates/rails/plugin_scaffold/test/dummy/config/initializers/filter_parameter_logging.rb +4 -0
- data/templates/rails/plugin_scaffold/test/dummy/config/initializers/inflections.rb +16 -0
- data/templates/rails/plugin_scaffold/test/dummy/config/initializers/mime_types.rb +4 -0
- data/templates/rails/plugin_scaffold/test/dummy/config/initializers/session_store.rb +3 -0
- data/templates/rails/plugin_scaffold/test/dummy/config/initializers/wrap_parameters.rb +14 -0
- data/templates/rails/plugin_scaffold/test/dummy/config/locales/en.yml +23 -0
- data/templates/rails/plugin_scaffold/test/dummy/config/routes.rb.tt +5 -0
- data/templates/rails/plugin_scaffold/test/dummy/config/secrets.yml +22 -0
- data/templates/rails/plugin_scaffold/test/dummy/config.ru +4 -0
- data/templates/rails/plugin_scaffold/test/dummy/db/seeds.rb +7 -0
- data/templates/rails/plugin_scaffold/test/dummy/public/404.html +67 -0
- data/templates/rails/plugin_scaffold/test/dummy/public/422.html +67 -0
- data/templates/rails/plugin_scaffold/test/dummy/public/500.html +66 -0
- data/templates/rails/plugin_scaffold/test/dummy/public/favicon.ico +0 -0
- data/templates/rails/rails_scaffold/lib/tasks/%gem_name%_tasks.rake.tt +4 -0
- data/templates/rails/rails_scaffold/test/dummy/README.rdoc +28 -0
- data/templates/rails/rails_scaffold/test/dummy/Rakefile +6 -0
- data/templates/rails/rails_scaffold/test/dummy/app/assets/javascripts/application.js +13 -0
- data/templates/rails/rails_scaffold/test/dummy/app/assets/stylesheets/application.sass +0 -0
- data/templates/rails/rails_scaffold/test/dummy/app/controllers/application_controller.rb +7 -0
- data/templates/rails/rails_scaffold/test/dummy/app/helpers/application_helper.rb +2 -0
- data/templates/rails/rails_scaffold/test/dummy/app/mailers/application_mailer.rb +4 -0
- data/templates/rails/rails_scaffold/test/dummy/app/views/layouts/application.html.erb +14 -0
- data/templates/rails/rails_scaffold/test/dummy/app/views/layouts/mailer.html.erb +9 -0
- data/templates/rails/rails_scaffold/test/dummy/app/views/layouts/mailer.text.erb +1 -0
- data/templates/rails/rails_scaffold/test/dummy/bin/bundle +4 -0
- data/templates/rails/rails_scaffold/test/dummy/bin/rails +5 -0
- data/templates/rails/rails_scaffold/test/dummy/bin/rake +6 -0
- data/templates/rails/rails_scaffold/test/dummy/bin/setup +30 -0
- data/templates/rails/rails_scaffold/test/dummy/config/application.rb.tt +26 -0
- data/templates/rails/rails_scaffold/test/dummy/config/boot.rb +5 -0
- data/templates/rails/rails_scaffold/test/dummy/config/database.yml +25 -0
- data/templates/rails/rails_scaffold/test/dummy/config/environment.rb +5 -0
- data/templates/rails/rails_scaffold/test/dummy/config/environments/development.rb +41 -0
- data/templates/rails/rails_scaffold/test/dummy/config/environments/production.rb +79 -0
- data/templates/rails/rails_scaffold/test/dummy/config/environments/test.rb +42 -0
- data/templates/rails/rails_scaffold/test/dummy/config/initializers/assets.rb +11 -0
- data/templates/rails/rails_scaffold/test/dummy/config/initializers/backtrace_silencers.rb +7 -0
- data/templates/rails/rails_scaffold/test/dummy/config/initializers/cookies_serializer.rb +3 -0
- data/templates/rails/rails_scaffold/test/dummy/config/initializers/filter_parameter_logging.rb +4 -0
- data/templates/rails/rails_scaffold/test/dummy/config/initializers/inflections.rb +16 -0
- data/templates/rails/rails_scaffold/test/dummy/config/initializers/mime_types.rb +4 -0
- data/templates/rails/rails_scaffold/test/dummy/config/initializers/session_store.rb +3 -0
- data/templates/rails/rails_scaffold/test/dummy/config/initializers/wrap_parameters.rb +14 -0
- data/templates/rails/rails_scaffold/test/dummy/config/locales/en.yml +23 -0
- data/templates/rails/rails_scaffold/test/dummy/config/routes.rb.tt +5 -0
- data/templates/rails/rails_scaffold/test/dummy/config/secrets.yml +22 -0
- data/templates/rails/rails_scaffold/test/dummy/config.ru +4 -0
- data/templates/rails/rails_scaffold/test/dummy/db/seeds.rb +7 -0
- data/templates/rails/rails_scaffold/test/dummy/public/404.html +67 -0
- data/templates/rails/rails_scaffold/test/dummy/public/422.html +67 -0
- data/templates/rails/rails_scaffold/test/dummy/public/500.html +66 -0
- data/templates/rails/rails_scaffold/test/dummy/public/favicon.ico +0 -0
- metadata +135 -4
- /data/{spec/status_persistence.txt → templates/rails/plugin_scaffold/test/dummy/app/assets/stylesheets/application.sass} +0 -0
@@ -0,0 +1,50 @@
|
|
1
|
+
require 'jekyll_plugin_support'
|
2
|
+
require_relative '<%= @gem_name %>/version.rb'
|
3
|
+
|
4
|
+
# This Jekyll block tag plugin is a minimal example.
|
5
|
+
#
|
6
|
+
# See https://www.mslinn.com/jekyll/10200-jekyll-plugin-background.html
|
7
|
+
# See https://www.mslinn.com/jekyll/10400-jekyll-plugin-template-collection.html
|
8
|
+
#
|
9
|
+
# @example Heading for this example
|
10
|
+
# Describe what this example does
|
11
|
+
# {% my_block_tag param1="value1" %}
|
12
|
+
# Hello, world!
|
13
|
+
# {% endmy_block_tag %}
|
14
|
+
#
|
15
|
+
# The Jekyll log level defaults to :info, which means all the Jekyll.logger statements below will not generate output.
|
16
|
+
# You can control the log level when you start Jekyll.
|
17
|
+
# To set the log level to :debug, write an entery into _config.yml, like this:
|
18
|
+
# plugin_loggers:
|
19
|
+
# MyBlockTag: debug
|
20
|
+
|
21
|
+
module <%= @class_name %>
|
22
|
+
# This class implements the Jekyll block tag functionality
|
23
|
+
class <%= @jekyll_class_name %> < JekyllSupport::JekyllBlock
|
24
|
+
PLUGIN_NAME = '<%= @block_name %>'.freeze
|
25
|
+
VERSION = <%= @class_name %>::VERSION
|
26
|
+
|
27
|
+
# Put your plugin logic here.
|
28
|
+
# The following variables are predefined:
|
29
|
+
# @argument_string, @block_name, @config, @envs, @helper, @layout, @logger, @mode, @page, @paginator, @site and @theme
|
30
|
+
#
|
31
|
+
# @return [String]
|
32
|
+
def render_impl(content)
|
33
|
+
<%= parse_jekyll_parameters %>
|
34
|
+
|
35
|
+
# Compute the return value of this Jekyll tag
|
36
|
+
<<~HEREDOC
|
37
|
+
<pre class="example">
|
38
|
+
content = '#{content}'
|
39
|
+
<%= dump_jekyll_parameters %>
|
40
|
+
Remaining markup: '#{@helper.remaining_markup}'.
|
41
|
+
</pre>
|
42
|
+
HEREDOC
|
43
|
+
rescue StandardError => e
|
44
|
+
@logger.error { "#{self.class} died with a #{e.full_message}" }
|
45
|
+
exit 3
|
46
|
+
end
|
47
|
+
|
48
|
+
JekyllPluginHelper.register(self, PLUGIN_NAME)
|
49
|
+
end
|
50
|
+
end
|
@@ -0,0 +1,13 @@
|
|
1
|
+
require_relative '../lib/<%= @gem_name %>'
|
2
|
+
|
3
|
+
RSpec.describe <%= @class_name %>::<%= @class_name %> do
|
4
|
+
let(:logger) do
|
5
|
+
PluginMetaLogger.instance.new_logger(self, PluginMetaLogger.instance.config)
|
6
|
+
end
|
7
|
+
|
8
|
+
let(:parse_context) { TestParseContext.new }
|
9
|
+
|
10
|
+
it 'has a test' do
|
11
|
+
expect(true).to be_true
|
12
|
+
end
|
13
|
+
end
|
@@ -0,0 +1,79 @@
|
|
1
|
+
require 'jekyll'
|
2
|
+
require 'jekyll_plugin_logger'
|
3
|
+
require 'liquid'
|
4
|
+
require 'fileutils'
|
5
|
+
require 'yaml'
|
6
|
+
require_relative '../lib/<%= @gem_name %>'
|
7
|
+
|
8
|
+
RSpec.configure do |config|
|
9
|
+
config.filter_run :focus
|
10
|
+
# config.order = 'random'
|
11
|
+
config.run_all_when_everything_filtered = true
|
12
|
+
|
13
|
+
# See https://relishapp.com/rspec/rspec-core/docs/command-line/only-failures
|
14
|
+
config.example_status_persistence_file_path = '../spec/status_persistence.txt'
|
15
|
+
|
16
|
+
config.filter_run_when_matching focus: true
|
17
|
+
end
|
18
|
+
|
19
|
+
Registers = Struct.new(:page, :site)
|
20
|
+
|
21
|
+
# Mock for Collections
|
22
|
+
class Collections
|
23
|
+
def values
|
24
|
+
[]
|
25
|
+
end
|
26
|
+
end
|
27
|
+
|
28
|
+
# Mock for Site
|
29
|
+
class SiteMock
|
30
|
+
attr_reader :config
|
31
|
+
|
32
|
+
def initialize
|
33
|
+
@config = YAML.safe_load(File.read('../demo/_config.yml'))
|
34
|
+
@config['env'] = { 'JEKYLL_ENV' => 'development' }
|
35
|
+
end
|
36
|
+
|
37
|
+
def collections
|
38
|
+
Collections.new
|
39
|
+
end
|
40
|
+
end
|
41
|
+
|
42
|
+
class TestLiquidContext < Liquid::Context
|
43
|
+
def initialize
|
44
|
+
super
|
45
|
+
|
46
|
+
page = {
|
47
|
+
'content' => 'blah blah',
|
48
|
+
'description' => 'Jekyll plugin support demo',
|
49
|
+
'dir' => '/',
|
50
|
+
'excerpt' => nil,
|
51
|
+
'layout' => 'default',
|
52
|
+
'name' => 'index.html',
|
53
|
+
'path' => 'index.html',
|
54
|
+
'title' => 'Welcome',
|
55
|
+
'url' => '/',
|
56
|
+
}
|
57
|
+
|
58
|
+
@content = 'Interior of the tag'
|
59
|
+
@registers = Registers.new(
|
60
|
+
page,
|
61
|
+
SiteMock.new
|
62
|
+
)
|
63
|
+
end
|
64
|
+
end
|
65
|
+
|
66
|
+
# Mock for Liquid::ParseContent
|
67
|
+
class TestParseContext < Liquid::ParseContext
|
68
|
+
attr_reader :line_number, :registers
|
69
|
+
|
70
|
+
def initialize
|
71
|
+
super
|
72
|
+
@line_number = 123
|
73
|
+
|
74
|
+
@registers = Registers.new(
|
75
|
+
{ 'path' => 'path/to/page.html' },
|
76
|
+
SiteMock.new
|
77
|
+
)
|
78
|
+
end
|
79
|
+
end
|
@@ -0,0 +1,21 @@
|
|
1
|
+
source 'https://rubygems.org'
|
2
|
+
|
3
|
+
# gem 'ffi'
|
4
|
+
gem 'jekyll', '>= 4.3.2'
|
5
|
+
# gem 'nokogumbo', '=2.0.3'
|
6
|
+
# gem 'ptools'
|
7
|
+
|
8
|
+
group :jekyll_plugins do
|
9
|
+
gem '<%= @gem_name %>', path: '../' # use unreleased gem dependencies defined in the parent project
|
10
|
+
gem 'classifier-reborn'
|
11
|
+
gem 'html-proofer'
|
12
|
+
gem 'jekyll-assets', git: 'https://github.com/envygeeks/jekyll-assets'
|
13
|
+
gem 'jekyll-environment-variables'
|
14
|
+
gem 'jekyll-tagging'
|
15
|
+
end
|
16
|
+
|
17
|
+
gem 'debase', '0.2.5.beta2', require: false
|
18
|
+
gem 'rspec-core', require: false
|
19
|
+
gem 'rubocop', require: false
|
20
|
+
gem 'rubocop-rspec', require: false
|
21
|
+
gem 'ruby-debug-ide', require: false
|
@@ -0,0 +1,71 @@
|
|
1
|
+
#!/bin/bash
|
2
|
+
|
3
|
+
# shellcheck disable=SC2086,SC2155,SC2059
|
4
|
+
|
5
|
+
function help {
|
6
|
+
echo "
|
7
|
+
$(basename $0) - Run the demo Jekyll website.
|
8
|
+
By default the demo Jekyll website runs without restriction under ruby-debug-ide and debase,
|
9
|
+
and listens on 0.0.0.0:1234.
|
10
|
+
Options:
|
11
|
+
-h Show this error message
|
12
|
+
-r Run freely, without a debugger
|
13
|
+
"
|
14
|
+
exit 1
|
15
|
+
}
|
16
|
+
|
17
|
+
|
18
|
+
unset RUN_FREE
|
19
|
+
while getopts "hr" OPT; do
|
20
|
+
case "$OPT" in
|
21
|
+
h) help ;;
|
22
|
+
|
23
|
+
r) export RUN_FREE=true
|
24
|
+
echo "The RUN_FREE option was specified (without a debugger)."
|
25
|
+
;;
|
26
|
+
|
27
|
+
*) help ;;
|
28
|
+
esac
|
29
|
+
done
|
30
|
+
shift $((OPTIND-1))
|
31
|
+
|
32
|
+
|
33
|
+
# Change to parent directory of this script
|
34
|
+
SOURCE=${BASH_SOURCE[0]}
|
35
|
+
while [ -L "$SOURCE" ]; do # resolve $SOURCE until the file is no longer a symlink
|
36
|
+
DIR=$( cd -P "$( dirname "$SOURCE" )" >/dev/null 2>&1 && pwd )
|
37
|
+
SOURCE=$(readlink "$SOURCE")
|
38
|
+
[[ $SOURCE != /* ]] && SOURCE=$DIR/$SOURCE # if $SOURCE was a relative symlink, we need to resolve it relative to the path where the symlink file was located
|
39
|
+
done
|
40
|
+
DIR=$( cd -P "$( dirname "$SOURCE" )" >/dev/null 2>&1 && pwd )
|
41
|
+
cd "$DIR/.."
|
42
|
+
|
43
|
+
# dispatcher-port and dispatcher-port are arbitrarily chosen to prevent conflicts with other instances.
|
44
|
+
|
45
|
+
run="serve \
|
46
|
+
--livereload_port 25721 \
|
47
|
+
--force_polling \
|
48
|
+
--host 0.0.0.0 \
|
49
|
+
--port 4444 \
|
50
|
+
--future \
|
51
|
+
--incremental \
|
52
|
+
--livereload \
|
53
|
+
--drafts \
|
54
|
+
--unpublished"
|
55
|
+
|
56
|
+
../bin/setup
|
57
|
+
|
58
|
+
rm -f Gemfile.lock
|
59
|
+
bundle
|
60
|
+
bundle exec ../binstub/jekyll clean # Ensure all hooks get called
|
61
|
+
|
62
|
+
if [ "$RUN_FREE" ]; then
|
63
|
+
bundle exec ../binstub/jekyll $run
|
64
|
+
else
|
65
|
+
bundle exec ../binstub/rdebug-ide \
|
66
|
+
--host 0.0.0.0 \
|
67
|
+
--port 1234 \
|
68
|
+
--dispatcher-port 26162 \
|
69
|
+
-- \
|
70
|
+
../binstub/jekyll $run
|
71
|
+
fi
|
@@ -0,0 +1,48 @@
|
|
1
|
+
author: <%= @repository.user %>
|
2
|
+
compress_html:
|
3
|
+
blanklines: false
|
4
|
+
clippings: all
|
5
|
+
comments: ["<!-- ", " -->"]
|
6
|
+
endings: all
|
7
|
+
ignore:
|
8
|
+
envs: [development]
|
9
|
+
profile: false
|
10
|
+
startings: [html, head, body]
|
11
|
+
domain: bogus.jekylldemo.com
|
12
|
+
email: bogus@jekylldemo.com
|
13
|
+
exclude: # Wildcards are not supported yet https://github.com/jekyll/jekyll-watch/pull/93
|
14
|
+
- .git
|
15
|
+
- .github
|
16
|
+
- .gitignore
|
17
|
+
- .jekyll-cache
|
18
|
+
- .jekyll-metadata
|
19
|
+
- .ruby-version
|
20
|
+
- .vscode
|
21
|
+
- BingSiteAuth.xml
|
22
|
+
- Gemfile
|
23
|
+
- Gemfile.lock
|
24
|
+
- README.md
|
25
|
+
ignore_theme_config: true
|
26
|
+
liquid:
|
27
|
+
error_mode: strict
|
28
|
+
# strict_filters: true
|
29
|
+
# strict_variables: true
|
30
|
+
plugin_loggers:
|
31
|
+
PluginMetaLogger: info
|
32
|
+
CleanHook: warn
|
33
|
+
DocumentHooks: warn
|
34
|
+
MyBlock: warn
|
35
|
+
PageHooks: warn
|
36
|
+
PostHooks: warn
|
37
|
+
SiteHooks: warn
|
38
|
+
permalink: "/blog/:year/:month/:day/:title:output_ext"
|
39
|
+
plugins: # Use file name of the plugin entry point, not the gem name
|
40
|
+
- classifier-reborn
|
41
|
+
- jekyll
|
42
|
+
- jekyll_plugin_logger
|
43
|
+
- html-proofer
|
44
|
+
- <%= @gem_name %>
|
45
|
+
sass:
|
46
|
+
style: compressed
|
47
|
+
title: <%= gem_name %> Demonstration
|
48
|
+
url: https://bogus.jekylldemo.com
|
@@ -0,0 +1,15 @@
|
|
1
|
+
---
|
2
|
+
categories: [Jekyll]
|
3
|
+
description: Just a draft test post I wrote
|
4
|
+
date: 2022-03-28
|
5
|
+
last_modified_at: 2022-04-12
|
6
|
+
layout: default
|
7
|
+
front_matter_variable: Provided in front matter
|
8
|
+
title: Test Draft Post
|
9
|
+
---
|
10
|
+
<h2>Hello, World!</h2>
|
11
|
+
|
12
|
+
<h3>The Future Is So Bright</h3>
|
13
|
+
<p>
|
14
|
+
Plugins <b>may</b> receive variables as arguments, if they are enclosed in double curly braces.
|
15
|
+
</p>
|
@@ -0,0 +1,9 @@
|
|
1
|
+
{% assign include_variable = "variable set in _includes/block_tag_template_wrapper" %}
|
2
|
+
{% block_tag_template param1='{{include_variable}}'
|
3
|
+
param2='{{include.param2}}'
|
4
|
+
param3='{{include.param3}}'
|
5
|
+
param4='{{page.last_modified_at}}'
|
6
|
+
param5='{{layout.compress}}'
|
7
|
+
remainder of invocation string %}
|
8
|
+
Hello, world!
|
9
|
+
{% endblock_tag_template %}
|
@@ -0,0 +1,67 @@
|
|
1
|
+
---
|
2
|
+
layout: compress
|
3
|
+
---
|
4
|
+
<!DOCTYPE html>
|
5
|
+
<html lang="{{ site.lang | default: "en-US" }}">
|
6
|
+
<head>
|
7
|
+
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
8
|
+
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
9
|
+
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
|
10
|
+
{% capture description %}{{ page.description | default: page.title | default: page.subtitle }}{% endcapture %}
|
11
|
+
{% capture page.title %}{{ page.title | default: page.subtitle }}{% endcapture %}
|
12
|
+
{% assign nowMillis = site.time | date: '%s' %}
|
13
|
+
<link rel="stylesheet" href="{{ '/assets/css/style.css?v=' | append: nowMillis }}" type="text/css">
|
14
|
+
|
15
|
+
{% assign csses = page.css | default: layout.css %}
|
16
|
+
{% for css in csses %}
|
17
|
+
<link rel="stylesheet" href="{{css | append: '?v=' | append: nowMillis }}" type="text/css">
|
18
|
+
{% endfor %}
|
19
|
+
|
20
|
+
<link rel="icon" type="image/png" href="/assets/images/favicon.png">
|
21
|
+
<!--[if lt IE 9]>
|
22
|
+
<script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
|
23
|
+
<![endif]-->
|
24
|
+
<title>{{ page.title-override | default: page.title | default: page.subtitle }}</title>
|
25
|
+
{% if page.keywords %}<meta name="keywords" content="{{page.keywords}}">{% endif %}
|
26
|
+
</head>
|
27
|
+
<body id="body">
|
28
|
+
<header>
|
29
|
+
<div class="inner">
|
30
|
+
<a href="/index.html">
|
31
|
+
<div class="h1">{{ site.title }}</div>
|
32
|
+
</a>
|
33
|
+
{% capture Title %}{{ page.title | default: layout.title }}{% endcapture %}
|
34
|
+
{% capture Subtitle %}{{ page.subtitle | default: layout.subtitle }}{% endcapture %}
|
35
|
+
<h1 id="headerH1">{{ Title | default: Subtitle }}</h1>
|
36
|
+
</div>
|
37
|
+
</header>
|
38
|
+
<div id="content-wrapper">
|
39
|
+
<div class="inner clearfix">
|
40
|
+
<nav id="sidebar">
|
41
|
+
<ul>
|
42
|
+
<li><a href="/index.html">Tests</a></li>
|
43
|
+
<li><a href="/blog/blogsByDate.html">Blog</a></li>
|
44
|
+
</ul>
|
45
|
+
</nav>
|
46
|
+
<section id="main-content">
|
47
|
+
{{ content }}
|
48
|
+
|
49
|
+
<p class="copyright" id="copyright" xmlns:dct="http://purl.org/dc/terms/" xmlns:vcard="http://www.w3.org/2001/vcard-rdf/3.0#">
|
50
|
+
<a rel="license" style="float: left; margin-right: 1em; padding-top: 9px; padding-bottom: 2em;"
|
51
|
+
href="http://creativecommons.org/publicdomain/zero/1.0/">
|
52
|
+
<img src="http://i.creativecommons.org/p/zero/1.0/88x31.png" style="border-style: none;" alt="CC0" />
|
53
|
+
</a>
|
54
|
+
To the extent possible under law,
|
55
|
+
<a rel="dct:publisher"
|
56
|
+
href="https://www.mslinn.com/jekyll/10400-jekyll-plugin-template-collection.html">
|
57
|
+
<span property="dct:title"><%= @repository.user_name %></span></a>
|
58
|
+
has waived all copyright and related or neighboring rights to
|
59
|
+
<span property="dct:title"><%= @gem_name %> Demonstration</span>.
|
60
|
+
This work is published from <span property="vcard:Country" datatype="dct:ISO3166" content="CA"
|
61
|
+
about="https://www.mslinn.com/jekyll/10400-jekyll-plugin-template-collection.html">Canada</span>.
|
62
|
+
</p>
|
63
|
+
</section>
|
64
|
+
</div>
|
65
|
+
</div>
|
66
|
+
</body>
|
67
|
+
</html>
|
@@ -0,0 +1,12 @@
|
|
1
|
+
---
|
2
|
+
categories: [Jekyll, Ruby]
|
3
|
+
description: Another test.
|
4
|
+
date: 2022-12-15
|
5
|
+
last_modified_at: 2022-12-15
|
6
|
+
layout: default
|
7
|
+
title: Another Test
|
8
|
+
---
|
9
|
+
<h2>Bogus Confidential Memo</h2>
|
10
|
+
<p>
|
11
|
+
Coca-Cola announced a merger with Pepsi that will happen on December 15th, 2222 for 200 trillion pounds of sugar.
|
12
|
+
</p>
|
@@ -0,0 +1,218 @@
|
|
1
|
+
* {
|
2
|
+
box-sizing: border-box;
|
3
|
+
}
|
4
|
+
|
5
|
+
a, a code, a.code, a .code, a tt {
|
6
|
+
color: #2879d0;
|
7
|
+
}
|
8
|
+
|
9
|
+
a {
|
10
|
+
text-decoration: none;
|
11
|
+
background-color: transparent;
|
12
|
+
}
|
13
|
+
|
14
|
+
body {
|
15
|
+
color: #333;
|
16
|
+
font-family: Merriweather, serif;
|
17
|
+
line-height: 1.5;
|
18
|
+
margin: 0;
|
19
|
+
}
|
20
|
+
|
21
|
+
code, pre, tt, .code, .codeLabel {
|
22
|
+
font-family: Monaco,"Bitstream Vera Sans Mono", "Lucida Console", Terminal, monospace;
|
23
|
+
font-stretch: semi-condensed;
|
24
|
+
}
|
25
|
+
|
26
|
+
code, .code {
|
27
|
+
font-size: smaller;
|
28
|
+
}
|
29
|
+
|
30
|
+
h1.code, h2.code, h3.code {
|
31
|
+
font-size: revert;
|
32
|
+
}
|
33
|
+
|
34
|
+
h1, .h1 {
|
35
|
+
display: block;
|
36
|
+
font-size: 2em;
|
37
|
+
font-weight: bold;
|
38
|
+
margin: 0.67em 0;
|
39
|
+
margin-block-start: 0.67em;
|
40
|
+
margin-block-end: 0.67em;
|
41
|
+
margin-inline-start: 0px;
|
42
|
+
margin-inline-end: 0px;
|
43
|
+
}
|
44
|
+
|
45
|
+
h1, h2, h3, header, nav#sidebar, .error {
|
46
|
+
font-family: "Helvetica Neue", Helvetica, Arial, serif;
|
47
|
+
}
|
48
|
+
|
49
|
+
header {
|
50
|
+
background: #095e2e;
|
51
|
+
display: flow-root;
|
52
|
+
height: 160px;
|
53
|
+
position: relative;
|
54
|
+
}
|
55
|
+
|
56
|
+
header div.h1 {
|
57
|
+
font-weight: bold;
|
58
|
+
color: #fff;
|
59
|
+
letter-spacing: -1px;
|
60
|
+
line-height: 1;
|
61
|
+
margin-bottom: 0.2em;
|
62
|
+
margin-top: 0;
|
63
|
+
}
|
64
|
+
|
65
|
+
header h1 {
|
66
|
+
color: #9dffe5;
|
67
|
+
letter-spacing: 0;
|
68
|
+
line-height: 1.3;
|
69
|
+
margin-bottom: 0;
|
70
|
+
margin-top: 0;
|
71
|
+
}
|
72
|
+
|
73
|
+
header > .inner {
|
74
|
+
padding-top: 40px;
|
75
|
+
}
|
76
|
+
|
77
|
+
nav#sidebar {
|
78
|
+
float: right;
|
79
|
+
line-height: 1.3;
|
80
|
+
min-height: 504px;
|
81
|
+
padding-left: 20px;
|
82
|
+
width: 200px;
|
83
|
+
}
|
84
|
+
|
85
|
+
pre {
|
86
|
+
background: #78B4DB21;
|
87
|
+
border: solid 1px #cecece;
|
88
|
+
overflow: auto;
|
89
|
+
padding: 4px;
|
90
|
+
text-indent: initial;
|
91
|
+
text-shadow: none;
|
92
|
+
font-size: 9pt;
|
93
|
+
margin-bottom: 10px;
|
94
|
+
margin-left: 0;
|
95
|
+
margin-right: 0;
|
96
|
+
}
|
97
|
+
|
98
|
+
#main-content {
|
99
|
+
margin-bottom: 2em;
|
100
|
+
}
|
101
|
+
|
102
|
+
#main-content {
|
103
|
+
float: left;
|
104
|
+
width: 690px;
|
105
|
+
}
|
106
|
+
|
107
|
+
.bg_yellow {
|
108
|
+
background-color: yellow;
|
109
|
+
}
|
110
|
+
|
111
|
+
.codeLabel {
|
112
|
+
color: white;
|
113
|
+
background-color: #666;
|
114
|
+
margin-bottom: 0;
|
115
|
+
padding-bottom: 0;
|
116
|
+
padding-left: 1em;
|
117
|
+
}
|
118
|
+
|
119
|
+
.codeLabel+pre {
|
120
|
+
margin-top: 0;
|
121
|
+
}
|
122
|
+
|
123
|
+
.copyright {
|
124
|
+
border-top: thin black solid;
|
125
|
+
clear: both;
|
126
|
+
margin-top: 2em;
|
127
|
+
padding-top: 0.5em;
|
128
|
+
}
|
129
|
+
|
130
|
+
.error {
|
131
|
+
color: red;
|
132
|
+
}
|
133
|
+
|
134
|
+
.example {
|
135
|
+
background-color: light-green;
|
136
|
+
border: thin lightgray solid;
|
137
|
+
padding: 5px;
|
138
|
+
}
|
139
|
+
|
140
|
+
.inner {
|
141
|
+
margin: 0 auto;
|
142
|
+
position: relative;
|
143
|
+
width: 940px;
|
144
|
+
}
|
145
|
+
|
146
|
+
.maxOneScreenHigh {
|
147
|
+
max-height: 500px;
|
148
|
+
}
|
149
|
+
|
150
|
+
.numbered_line,
|
151
|
+
.unselectable.numbered_line,
|
152
|
+
.numbered_line.unselectable {
|
153
|
+
color: #5fb25f;
|
154
|
+
}
|
155
|
+
|
156
|
+
.unselectable {
|
157
|
+
color: #7922f9;
|
158
|
+
-moz-user-select: none;
|
159
|
+
-khtml-user-select: none;
|
160
|
+
user-select: none;
|
161
|
+
}
|
162
|
+
|
163
|
+
|
164
|
+
@media only screen and (min-width: 768px) and (max-width: 959px) {
|
165
|
+
.inner {
|
166
|
+
width: 740px;
|
167
|
+
}
|
168
|
+
|
169
|
+
#main-content {
|
170
|
+
width: 490px;
|
171
|
+
}
|
172
|
+
}
|
173
|
+
|
174
|
+
@media only screen and (min-width: 768px) {
|
175
|
+
#tocSide {
|
176
|
+
position: relative;
|
177
|
+
right: 0;
|
178
|
+
width: 220px;
|
179
|
+
display: block;
|
180
|
+
}
|
181
|
+
|
182
|
+
#tocMain {
|
183
|
+
display: none;
|
184
|
+
}
|
185
|
+
}
|
186
|
+
|
187
|
+
|
188
|
+
@media only screen and (max-width: 767px) {
|
189
|
+
.inner {
|
190
|
+
width: 93%;
|
191
|
+
}
|
192
|
+
|
193
|
+
#main-content,
|
194
|
+
nav#sidebar {
|
195
|
+
float: none;
|
196
|
+
width: 100% ! important;
|
197
|
+
}
|
198
|
+
|
199
|
+
nav#sidebar {
|
200
|
+
background-image: none;
|
201
|
+
border-top: solid 1px #ddd;
|
202
|
+
margin-top: 20px;
|
203
|
+
min-height: 0;
|
204
|
+
padding: 20px 0;
|
205
|
+
}
|
206
|
+
|
207
|
+
nav#sidebar a.button {
|
208
|
+
display: none;
|
209
|
+
}
|
210
|
+
|
211
|
+
#tocSide {
|
212
|
+
display: none;
|
213
|
+
}
|
214
|
+
|
215
|
+
#tocMain {
|
216
|
+
display: block;
|
217
|
+
}
|
218
|
+
}
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
@@ -0,0 +1,7 @@
|
|
1
|
+
/*!
|
2
|
+
* clipboard.js v2.0.6
|
3
|
+
* https://clipboardjs.com/
|
4
|
+
*
|
5
|
+
* Licensed MIT © Zeno Rocha
|
6
|
+
*/
|
7
|
+
!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.ClipboardJS=e():t.ClipboardJS=e()}(this,function(){return o={},r.m=n=[function(t,e){t.exports=function(t){var e;if("SELECT"===t.nodeName)t.focus(),e=t.value;else if("INPUT"===t.nodeName||"TEXTAREA"===t.nodeName){var n=t.hasAttribute("readonly");n||t.setAttribute("readonly",""),t.select(),t.setSelectionRange(0,t.value.length),n||t.removeAttribute("readonly"),e=t.value}else{t.hasAttribute("contenteditable")&&t.focus();var o=window.getSelection(),r=document.createRange();r.selectNodeContents(t),o.removeAllRanges(),o.addRange(r),e=o.toString()}return e}},function(t,e){function n(){}n.prototype={on:function(t,e,n){var o=this.e||(this.e={});return(o[t]||(o[t]=[])).push({fn:e,ctx:n}),this},once:function(t,e,n){var o=this;function r(){o.off(t,r),e.apply(n,arguments)}return r._=e,this.on(t,r,n)},emit:function(t){for(var e=[].slice.call(arguments,1),n=((this.e||(this.e={}))[t]||[]).slice(),o=0,r=n.length;o<r;o++)n[o].fn.apply(n[o].ctx,e);return this},off:function(t,e){var n=this.e||(this.e={}),o=n[t],r=[];if(o&&e)for(var i=0,a=o.length;i<a;i++)o[i].fn!==e&&o[i].fn._!==e&&r.push(o[i]);return r.length?n[t]=r:delete n[t],this}},t.exports=n,t.exports.TinyEmitter=n},function(t,e,n){var d=n(3),h=n(4);t.exports=function(t,e,n){if(!t&&!e&&!n)throw new Error("Missing required arguments");if(!d.string(e))throw new TypeError("Second argument must be a String");if(!d.fn(n))throw new TypeError("Third argument must be a Function");if(d.node(t))return s=e,f=n,(u=t).addEventListener(s,f),{destroy:function(){u.removeEventListener(s,f)}};if(d.nodeList(t))return a=t,c=e,l=n,Array.prototype.forEach.call(a,function(t){t.addEventListener(c,l)}),{destroy:function(){Array.prototype.forEach.call(a,function(t){t.removeEventListener(c,l)})}};if(d.string(t))return o=t,r=e,i=n,h(document.body,o,r,i);throw new TypeError("First argument must be a String, HTMLElement, HTMLCollection, or NodeList");var o,r,i,a,c,l,u,s,f}},function(t,n){n.node=function(t){return void 0!==t&&t instanceof HTMLElement&&1===t.nodeType},n.nodeList=function(t){var e=Object.prototype.toString.call(t);return void 0!==t&&("[object NodeList]"===e||"[object HTMLCollection]"===e)&&"length"in t&&(0===t.length||n.node(t[0]))},n.string=function(t){return"string"==typeof t||t instanceof String},n.fn=function(t){return"[object Function]"===Object.prototype.toString.call(t)}},function(t,e,n){var a=n(5);function i(t,e,n,o,r){var i=function(e,n,t,o){return function(t){t.delegateTarget=a(t.target,n),t.delegateTarget&&o.call(e,t)}}.apply(this,arguments);return t.addEventListener(n,i,r),{destroy:function(){t.removeEventListener(n,i,r)}}}t.exports=function(t,e,n,o,r){return"function"==typeof t.addEventListener?i.apply(null,arguments):"function"==typeof n?i.bind(null,document).apply(null,arguments):("string"==typeof t&&(t=document.querySelectorAll(t)),Array.prototype.map.call(t,function(t){return i(t,e,n,o,r)}))}},function(t,e){if("undefined"!=typeof Element&&!Element.prototype.matches){var n=Element.prototype;n.matches=n.matchesSelector||n.mozMatchesSelector||n.msMatchesSelector||n.oMatchesSelector||n.webkitMatchesSelector}t.exports=function(t,e){for(;t&&9!==t.nodeType;){if("function"==typeof t.matches&&t.matches(e))return t;t=t.parentNode}}},function(t,e,n){"use strict";n.r(e);var o=n(0),r=n.n(o),i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t};function a(t,e){for(var n=0;n<e.length;n++){var o=e[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(t,o.key,o)}}function c(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,c),this.resolveOptions(t),this.initSelection()}var l=(function(t,e,n){return e&&a(t.prototype,e),n&&a(t,n),t}(c,[{key:"resolveOptions",value:function(t){var e=0<arguments.length&&void 0!==t?t:{};this.action=e.action,this.container=e.container,this.emitter=e.emitter,this.target=e.target,this.text=e.text,this.trigger=e.trigger,this.selectedText=""}},{key:"initSelection",value:function(){this.text?this.selectFake():this.target&&this.selectTarget()}},{key:"selectFake",value:function(){var t=this,e="rtl"==document.documentElement.getAttribute("dir");this.removeFake(),this.fakeHandlerCallback=function(){return t.removeFake()},this.fakeHandler=this.container.addEventListener("click",this.fakeHandlerCallback)||!0,this.fakeElem=document.createElement("textarea"),this.fakeElem.style.fontSize="12pt",this.fakeElem.style.border="0",this.fakeElem.style.padding="0",this.fakeElem.style.margin="0",this.fakeElem.style.position="absolute",this.fakeElem.style[e?"right":"left"]="-9999px";var n=window.pageYOffset||document.documentElement.scrollTop;this.fakeElem.style.top=n+"px",this.fakeElem.setAttribute("readonly",""),this.fakeElem.value=this.text,this.container.appendChild(this.fakeElem),this.selectedText=r()(this.fakeElem),this.copyText()}},{key:"removeFake",value:function(){this.fakeHandler&&(this.container.removeEventListener("click",this.fakeHandlerCallback),this.fakeHandler=null,this.fakeHandlerCallback=null),this.fakeElem&&(this.container.removeChild(this.fakeElem),this.fakeElem=null)}},{key:"selectTarget",value:function(){this.selectedText=r()(this.target),this.copyText()}},{key:"copyText",value:function(){var e=void 0;try{e=document.execCommand(this.action)}catch(t){e=!1}this.handleResult(e)}},{key:"handleResult",value:function(t){this.emitter.emit(t?"success":"error",{action:this.action,text:this.selectedText,trigger:this.trigger,clearSelection:this.clearSelection.bind(this)})}},{key:"clearSelection",value:function(){this.trigger&&this.trigger.focus(),document.activeElement.blur(),window.getSelection().removeAllRanges()}},{key:"destroy",value:function(){this.removeFake()}},{key:"action",set:function(t){var e=0<arguments.length&&void 0!==t?t:"copy";if(this._action=e,"copy"!==this._action&&"cut"!==this._action)throw new Error('Invalid "action" value, use either "copy" or "cut"')},get:function(){return this._action}},{key:"target",set:function(t){if(void 0!==t){if(!t||"object"!==(void 0===t?"undefined":i(t))||1!==t.nodeType)throw new Error('Invalid "target" value, use a valid Element');if("copy"===this.action&&t.hasAttribute("disabled"))throw new Error('Invalid "target" attribute. Please use "readonly" instead of "disabled" attribute');if("cut"===this.action&&(t.hasAttribute("readonly")||t.hasAttribute("disabled")))throw new Error('Invalid "target" attribute. You can\'t cut text from elements with "readonly" or "disabled" attributes');this._target=t}},get:function(){return this._target}}]),c),u=n(1),s=n.n(u),f=n(2),d=n.n(f),h="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},p=function(t,e,n){return e&&y(t.prototype,e),n&&y(t,n),t};function y(t,e){for(var n=0;n<e.length;n++){var o=e[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(t,o.key,o)}}var m=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(v,s.a),p(v,[{key:"resolveOptions",value:function(t){var e=0<arguments.length&&void 0!==t?t:{};this.action="function"==typeof e.action?e.action:this.defaultAction,this.target="function"==typeof e.target?e.target:this.defaultTarget,this.text="function"==typeof e.text?e.text:this.defaultText,this.container="object"===h(e.container)?e.container:document.body}},{key:"listenClick",value:function(t){var e=this;this.listener=d()(t,"click",function(t){return e.onClick(t)})}},{key:"onClick",value:function(t){var e=t.delegateTarget||t.currentTarget;this.clipboardAction&&(this.clipboardAction=null),this.clipboardAction=new l({action:this.action(e),target:this.target(e),text:this.text(e),container:this.container,trigger:e,emitter:this})}},{key:"defaultAction",value:function(t){return b("action",t)}},{key:"defaultTarget",value:function(t){var e=b("target",t);if(e)return document.querySelector(e)}},{key:"defaultText",value:function(t){return b("text",t)}},{key:"destroy",value:function(){this.listener.destroy(),this.clipboardAction&&(this.clipboardAction.destroy(),this.clipboardAction=null)}}],[{key:"isSupported",value:function(t){var e=0<arguments.length&&void 0!==t?t:["copy","cut"],n="string"==typeof e?[e]:e,o=!!document.queryCommandSupported;return n.forEach(function(t){o=o&&!!document.queryCommandSupported(t)}),o}}]),v);function v(t,e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,v);var n=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(v.__proto__||Object.getPrototypeOf(v)).call(this));return n.resolveOptions(e),n.listenClick(t),n}function b(t,e){var n="data-clipboard-"+t;if(e.hasAttribute(n))return e.getAttribute(n)}e.default=m}],r.c=o,r.d=function(t,e,n){r.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:n})},r.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)r.d(n,o,function(t){return e[t]}.bind(null,o));return n},r.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return r.d(e,"a",e),e},r.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},r.p="",r(r.s=6).default;function r(t){if(o[t])return o[t].exports;var e=o[t]={i:t,l:!1,exports:{}};return n[t].call(e.exports,e,e.exports,r),e.l=!0,e.exports}var n,o});
|