Skip to content

Commit

Permalink
app: more fixes to get JS-compiled CSS
Browse files Browse the repository at this point in the history
  • Loading branch information
freesteph committed Feb 23, 2021
1 parent 7f5eb44 commit 45ea735
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 30 deletions.
1 change: 0 additions & 1 deletion app/assets/config/manifest.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
//= link_tree ../images
//= link_directory ../javascripts .js
//= link_directory ../stylesheets .css
15 changes: 0 additions & 15 deletions app/assets/stylesheets/application.scss

This file was deleted.

7 changes: 0 additions & 7 deletions app/assets/stylesheets/components.scss

This file was deleted.

9 changes: 9 additions & 0 deletions app/javascript/packs/application.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
/* @import "tailwindcss/base"; */
/* @import "tailwindcss/components"; */
/* @import "tailwindcss/utilities"; */

/* @import "../stylesheets/base.css"; */

body {
background: red !important;
}
5 changes: 3 additions & 2 deletions app/javascript/packs/application.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,13 @@
// To reference this file, add <%= javascript_pack_tag 'application' %> to the appropriate
// layout file, like app/views/layouts/application.html.erb


// Uncomment to copy all static images under ../images to the output folder and reference
// them with the image_pack_tag helper in views (e.g <%= image_pack_tag 'rails.png' %>)
// or the `imagePath` JavaScript helper below.
//
// const images = require.context('../images', true)
// const imagePath = (name) => images(name, true)

console.log('Hello World from Webpacker')
import("./application.css");

console.log("Hello World from Webpacker");
6 changes: 1 addition & 5 deletions app/models/theme.rb
Original file line number Diff line number Diff line change
Expand Up @@ -126,11 +126,7 @@ def preview
dimensions = "#{1600 / factor}x#{1200 / factor}"

# FIXME: figure out if this operation is cached or not
thumbnail.image.variant(combine_options: {
gravity: 'SouthWest',
crop: "#{dimensions}+0+0",
resize: '300x300^'
})
thumbnail.image
end

def make_datetime(version)
Expand Down

0 comments on commit 45ea735

Please sign in to comment.