Sha256: cfecc2f7f2472a24c3be946c8f653e5d26d4ce50ab4bf7c7ea3615514a4f7c2f

Contents?: true

Size: 885 Bytes

Versions: 12

Compression:

Stored size: 885 Bytes

Contents

# card, that lists all styles that belong to one mod, for example:
# "mod: bootstrap+*style"

include_set Abstract::AssetInputter, input_format: :scss
include_set Abstract::ModAssets

def subpath
  "style"
end

def folder_group_type_id
  ::Card::LocalStyleFolderGroupID
end

def local_manifest_group_type_id
  ::Card::LocalStyleManifestGroupID
end

format :html do
  view :stylesheet_include_tag do
    card.item_cards.map do |icard|
      nest icard, view: :stylesheet_include_tag
    end.join("\n")
  end

  view :remote_include_tags do
    map_remote_items do |tag_args|
      tag "link",
          href: tag_args.delete("src"),
          media: "all", rel: "stylesheet", type: "text/css"
    end
  end
end

def asset_input_needs_refresh?
  !asset_input_updated_at || source_changed?(since: asset_input_updated_at)
end

def asset_input_updated_at
  asset_input_card&.updated_at
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
card-mod-style-0.18.1 set/type_plus_right/mod/style.rb
card-mod-style-0.18.0 set/type_plus_right/mod/style.rb
card-mod-style-0.17.0 set/type_plus_right/mod/style.rb
card-mod-style-0.16.0 set/type_plus_right/mod/style.rb
card-mod-style-0.15.6 set/type_plus_right/mod/style.rb
card-mod-style-0.15.5 set/type_plus_right/mod/style.rb
card-mod-style-0.15.4 set/type_plus_right/mod/style.rb
card-mod-style-0.15.3 set/type_plus_right/mod/style.rb
card-mod-style-0.15.2.pre1 set/type_plus_right/mod/style.rb
card-mod-style-0.15.1.1 set/type_plus_right/mod/style.rb
card-mod-style-0.15.1 set/type_plus_right/mod/style.rb
card-mod-style-0.15.0 set/type_plus_right/mod/style.rb