GithubHelp home page GithubHelp logo

Comments (12)

benlevydesign avatar benlevydesign commented on June 12, 2024

@Robdel12 or @wwilsman: Any ideas?

Thanks so much!

from dropkick.

Robdel12 avatar Robdel12 commented on June 12, 2024

Hey @benlevywebdesign! Sorry for the delayed response. I've been in the middle of a move for a week (just got internet back today! :p). I hope to be able to get to this over the weekend though!

from dropkick.

benlevydesign avatar benlevydesign commented on June 12, 2024

No worries, It's probably something so simple I'm missing. I'm not sure though...

from dropkick.

benlevydesign avatar benlevydesign commented on June 12, 2024

I'm going to try something. It probably won't work, but I'm going to try hosting the icon font myself and see what happens...

from dropkick.

Robdel12 avatar Robdel12 commented on June 12, 2024

I was thinking about this and I wonder if it's because icon fonts can't be rendered in a normal select. I'm sure there's something in DK we can do to fix that, but I think that's the issue here.

from dropkick.

wwilsman avatar wwilsman commented on June 12, 2024

I'm betting it has something to do with the innerHTML property. That property parses the html. I think what we'll want is textContent.

There's a few places we reference innerHTML we'll need to replace if this is the case

from dropkick.

benlevydesign avatar benlevydesign commented on June 12, 2024

Should I try replacing innerHTML with textContent? I would do this in the JS file?

from dropkick.

Robdel12 avatar Robdel12 commented on June 12, 2024

Just to give an update: in-between unpackings I've tried to reproduce / fix the issue but I haven't been able to even get the icon to render. Curious if this is something older DK can do and not the latest release. (I see you're using 2.1.7)

I tried going brute force and replacing innerHTML with textContent but that breaks DK, haha. I'm going to need to carve out some time for this one.

from dropkick.

benlevydesign avatar benlevydesign commented on June 12, 2024

Any enlightening discoveries?

from dropkick.

Robdel12 avatar Robdel12 commented on June 12, 2024

Hey @benlevywebdesign I haven't had time to really dig into this but I do know this will be a tough one to solve. Mainly because icons aren't supported in regular <selects>, which is what DropKick uses to build itself. We'll have to make sure we handle the cases for scrubbing out the icon from the value attribute too.

This should be a feature that we add for sure though.

from dropkick.

benlevydesign avatar benlevydesign commented on June 12, 2024

Hmm, yeah thats true with regular selects too I supposes. I thought I'd have to insert <i class="material-icons">&#xEB47;</i> into my databse to echo it back on the page but I think the easiest thing to do would be for me to use just text in the select and echo out the result as the icon with some if else statements. I'm not so concerned with having the icon display as the selects element. If you want to mark this issue closed you can.

from dropkick.

Robdel12 avatar Robdel12 commented on June 12, 2024

I think this is something DropKick should do though. This is a pretty common reason why someone would use a select replacement over a normal select.

Thanks for raising the issue :D

from dropkick.

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.