From 5571dc766e2143e39762ff0b47c41d1c2e154f4c Mon Sep 17 00:00:00 2001 From: Benjamin Sanders Date: Sat, 11 Oct 2025 10:34:24 -0400 Subject: Vendor bundled gems for deployment --- .../gems/kramdown-2.5.1/lib/kramdown/utils.rb | 45 ++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 vendor/bundle/ruby/3.4.0/gems/kramdown-2.5.1/lib/kramdown/utils.rb (limited to 'vendor/bundle/ruby/3.4.0/gems/kramdown-2.5.1/lib/kramdown/utils.rb') diff --git a/vendor/bundle/ruby/3.4.0/gems/kramdown-2.5.1/lib/kramdown/utils.rb b/vendor/bundle/ruby/3.4.0/gems/kramdown-2.5.1/lib/kramdown/utils.rb new file mode 100644 index 0000000..5928def --- /dev/null +++ b/vendor/bundle/ruby/3.4.0/gems/kramdown-2.5.1/lib/kramdown/utils.rb @@ -0,0 +1,45 @@ +# -*- coding: utf-8; frozen_string_literal: true -*- +# +#-- +# Copyright (C) 2009-2019 Thomas Leitner +# +# This file is part of kramdown which is licensed under the MIT. +#++ +# + +module Kramdown + + # == \Utils Module + # + # This module contains utility class/modules/methods that can be used by both parsers and + # converters. + module Utils + + autoload :Entities, 'kramdown/utils/entities' + autoload :Html, 'kramdown/utils/html' + autoload :Unidecoder, 'kramdown/utils/unidecoder' + autoload :StringScanner, 'kramdown/utils/string_scanner' + autoload :Configurable, 'kramdown/utils/configurable' + autoload :LRUCache, 'kramdown/utils/lru_cache' + + # Treat +name+ as if it were snake cased (e.g. snake_case) and camelize it (e.g. SnakeCase). + def self.camelize(name) + name.split('_').inject(+'') {|s, x| s << x[0..0].upcase << x[1..-1] } + end + + # Treat +name+ as if it were camelized (e.g. CamelizedName) and snake-case it (e.g. camelized_name). + def self.snake_case(name) + name = name.dup + name.gsub!(/([A-Z]+)([A-Z][a-z])/, '\1_\2') + name.gsub!(/([a-z])([A-Z])/, '\1_\2') + name.downcase! + name + end + + def self.deep_const_get(str) + ::Object.const_get(str) + end + + end + +end -- cgit v1.2.3