Git Product home page Git Product logo

Comments (7)

maxmx avatar maxmx commented on May 24, 2024

I initially made sure this would work without nib because the first project I used this on did ot include nib.

I've tried using this library on another project which included nib, no collisions or errors happened.

This means that you could use this in a nib-enabled dev environment without worries.

However, if you are suggesting that I'd translate some of the mixins to use nib in order to make the port of bootstrap to stylus leaner/cleaner, I probably wont do it, the css output would be the same (more work for same result).

Maybe I'll do it for Bootstrap 3 when it comes out.

from bootstrap-stylus.

yoshuawuyts avatar yoshuawuyts commented on May 24, 2024

+1 for lean/clean code. Having nib integration would be awesome.

from bootstrap-stylus.

skw avatar skw commented on May 24, 2024

Ya, 3.0 using nib mixins would be awesome! Just out of curiosity are you using a variation of the less>stylus parser floating around various gists?

from bootstrap-stylus.

maxmx avatar maxmx commented on May 24, 2024

I do it all by hand, I looked into the parsers but found none that would make the job perfectly and figuring where the parser fucked up is actually longer than doing everything manually. Took maybe 2 hours the first time and updating it now only takes a few minutes using a diff of the files.

I don't go around optimizing everything though, hence no nib integration.

I also wanted to be able to maintain it efficiently, unlike all the other bootstrap -> stylus projects that stopped pushing updates after releasing 1 version.

Seeing as they dont go and change the mixins every release, I'll see what I can do for nib integration for version 3.

from bootstrap-stylus.

getvega avatar getvega commented on May 24, 2024

Hi there - thanks for this great up-to-date port !! Are you sure this compiles in a nib-enabled environment ? Here is what happens on my side with stylus 0.32.0 & nib 0.9.1 :

Error: /XYZ/node_modules/nib/lib/nib/gradients.styl:125
   121|       add-property(prop, replace(val, '__CALL__', img))
   122|     start = start[1]
   123| 
   124|   // legacy webkit
 > 125|   end = grad-point(opposite-position(start))
   126|   webkit-legacy = '-webkit-gradient(linear, %s, %s, %s)' % (grad-point(start) end join-stops(stops, webkit-stop))
   127|   add-property(prop, replace(val, '__CALL__', webkit-legacy))
   128| 

invalid position to
    at gradient-vertical() (/mnt/hgfs/dev/node/korpo/public/lib/bootstrap-stylus/stylus/mixins.styl:407)
    at ".dropdown-menu > li > a:hover" (/mnt/hgfs/dev/node/korpo/public/lib/bootstrap-stylus/stylus/dropdowns.styl:89)

    at /XYZ/node_modules/stylus/lib/functions/index.js:724:22
    at exports.opposite-position (/XYZ/node_modules/stylus/lib/functions/index.js:725:8)
    at Array.forEach (native)
    at Evaluator.oppositePosition (/XYZ/node_modules/stylus/lib/functions/index.js:716:33)
    at Evaluator.invokeBuiltin (/XYZ/node_modules/stylus/lib/visitor/evaluator.js:811:30)
    at Evaluator.visitCall (/XYZ/node_modules/stylus/lib/visitor/evaluator.js:352:16)
    at Evaluator.Visitor.visit (/XYZ/node_modules/stylus/lib/visitor/index.js:28:40)
    at Evaluator.visit (/XYZ/node_modules/stylus/lib/visitor/evaluator.js:75:18)
    at Evaluator.visitExpression (/XYZ/node_modules/stylus/lib/visitor/evaluator.js:480:26)
    at Evaluator.Visitor.visit (/XYZ/node_modules/stylus/lib/visitor/index.js:28:40)

from bootstrap-stylus.

skw avatar skw commented on May 24, 2024

In what order are you order are you importing bootstrap.styl and nib? I believe it works as long as you import bootstrap first, followed by nib, otherwise it tries to render(transpile..) bootstrap with nib mixins.

Hopefully that is correct/ makes sense.

@import 'bootstrap/bootstrap.styl'
@import 'nib'
// your styles

from bootstrap-stylus.

getvega avatar getvega commented on May 24, 2024

Indeed it fixed the problem, thanks!

from bootstrap-stylus.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.