Browse Source

Add autoprefixer to css build (#6029)

* Add autoprefixer to css build

* also use autoprefixer on theme files
tags/v1.9.0-dev
silverwind 5 years ago
parent
commit
353282e658
8 changed files with 780 additions and 535 deletions
  1. 1
    2
      .editorconfig
  2. 2
    0
      Makefile
  3. 769
    509
      package-lock.json
  4. 7
    5
      package.json
  5. 1
    1
      public/css/index.css
  6. 0
    9
      public/less/_base.less
  7. 0
    2
      public/less/_form.less
  8. 0
    7
      public/less/_repository.less

+ 1
- 2
.editorconfig View File

# http://editorconfig.org # http://editorconfig.org

root = true root = true


[*] [*]
indent_style = space indent_style = space
indent_size = 4 indent_size = 4


[*.{yml}]
[*.{yml,json}]
indent_style = space indent_style = space
indent_size = 2 indent_size = 2



+ 2
- 0
Makefile View File



.PHONY: generate-stylesheets .PHONY: generate-stylesheets
generate-stylesheets: generate-stylesheets:
$(eval BROWSERS := "> 2%, last 2 firefox versions, last 2 safari versions")
node_modules/.bin/lessc --clean-css public/less/index.less public/css/index.css node_modules/.bin/lessc --clean-css public/less/index.less public/css/index.css
$(foreach file, $(filter-out public/less/themes/_base.less, $(wildcard public/less/themes/*)),node_modules/.bin/lessc --clean-css public/less/themes/$(notdir $(file)) > public/css/theme-$(notdir $(call strip-suffix,$(file))).css;) $(foreach file, $(filter-out public/less/themes/_base.less, $(wildcard public/less/themes/*)),node_modules/.bin/lessc --clean-css public/less/themes/$(notdir $(file)) > public/css/theme-$(notdir $(call strip-suffix,$(file))).css;)
$(foreach file, $(wildcard public/css/*),node_modules/.bin/postcss --use autoprefixer --autoprefixer.browsers $(BROWSERS) -o $(file) $(file);)


.PHONY: swagger-ui .PHONY: swagger-ui
swagger-ui: swagger-ui:

+ 769
- 509
package-lock.json
File diff suppressed because it is too large
View File


+ 7
- 5
package.json View File

{ {
"license": "MIT",
"devDependencies": {
"less": "^3.9.0",
"less-plugin-clean-css": "^1.5.1"
}
"license": "MIT",
"devDependencies": {
"autoprefixer": "9.4.7",
"less": "3.9.0",
"less-plugin-clean-css": "1.5.1",
"postcss-cli-simple": "3.0.0"
}
} }

+ 1
- 1
public/css/index.css
File diff suppressed because it is too large
View File


+ 0
- 9
public/less/_base.less View File

word-break: break-all; word-break: break-all;


/* Adds a hyphen where the word breaks, if supported (No Blink) */ /* Adds a hyphen where the word breaks, if supported (No Blink) */
-ms-hyphens: auto;
-moz-hyphens: auto;
-webkit-hyphens: auto;
hyphens: auto; hyphens: auto;
} }
.full.height { .full.height {
// no, stackable won't work on right menus. // no, stackable won't work on right menus.
margin-left: auto; margin-left: auto;
display: flex; display: flex;
display: -ms-flexbox;
-ms-flex-align: inherit;
align-items: inherit; align-items: inherit;
-ms-flex-direction: inherit;
flex-direction: inherit; flex-direction: inherit;
} }


} }


&.button, &.menu .item { &.button, &.menu .item {
-moz-user-select: auto;
-ms-user-select: auto;
-webkit-user-select: auto;
user-select: auto; user-select: auto;
} }



+ 0
- 2
public/less/_form.less View File

@media screen and (max-height: 575px){ @media screen and (max-height: 575px){
#rc-imageselect, .g-recaptcha { #rc-imageselect, .g-recaptcha {
transform:scale(0.77); transform:scale(0.77);
-webkit-transform:scale(0.77);
transform-origin:0 0; transform-origin:0 0;
-webkit-transform-origin:0 0;
} }
} }



+ 0
- 7
public/less/_repository.less View File

color: #999; color: #999;
background: #f5f5f5; background: #f5f5f5;
width: 1%; width: 1%;
-moz-user-select: none;
-ms-user-select: none;
-webkit-user-select: none;
user-select: none; user-select: none;


span { span {
color: #A7A7A7; color: #A7A7A7;
background: #fafafa; background: #fafafa;
width: 1%; width: 1%;
-moz-user-select: none;
-ms-user-select: none;
-webkit-user-select: none;
user-select: none; user-select: none;
vertical-align: top; vertical-align: top;


.generate-tab-size(@n, @i: 1) when (@i =< @n) { .generate-tab-size(@n, @i: 1) when (@i =< @n) {
.tab-size-@{i} { .tab-size-@{i} {
tab-size: @i !important; tab-size: @i !important;
-moz-tab-size: @i !important;
} }
.generate-tab-size(@n, (@i + 1)); .generate-tab-size(@n, (@i + 1));
} }

Loading…
Cancel
Save