Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

icon.fonts - choose other icon libraries #59

Closed
wernerdaehn opened this issue Aug 9, 2019 · 6 comments · Fixed by #80
Closed

icon.fonts - choose other icon libraries #59

wernerdaehn opened this issue Aug 9, 2019 · 6 comments · Fixed by #80
Labels
enhancement New feature or request good first issue Good for newcomers help wanted Extra attention is needed released

Comments

@wernerdaehn
Copy link

Would love to get a higher degree of freedom in the network.nodes.icon.face option.
To be more concrete, these icons as well.
https://openui5.hana.ondemand.com/test-resources/sap/m/demokit/iconExplorer/webapp/index.html#/overview/SAP-icons

Quite frankly I don't understand why you cannot set any value there and it gets added as the element's style={font-family: xxxx}.

Thanks in advance for considering.

@mojoaxel mojoaxel added enhancement New feature or request good first issue Good for newcomers help wanted Extra attention is needed labels Aug 9, 2019
@mojoaxel mojoaxel changed the title Network icons - choose other icon libraries icon.fonts - choose other icon libraries Aug 9, 2019
@Thomaash
Copy link
Member

Hi @wernerdaehn, could you provide an MWE please? Because this seems to work just fine to me: http://jsfiddle.net/wpcr1qfs/. Although you have to ensure that the icons are loaded before the initial rendering happens, otherwise they will appear only after zooming or similar actions.

@wernerdaehn
Copy link
Author

Well, that would be even better if this is just a doc issue. From your code I don't understand where the "Material Design Icons" get loaded and defined. Can you do me a favor and modify your code so that on of the SAP-Icons is used? Just to proof the point.

@Thomaash
Copy link
Member

I have no idea about SAP-Icons and I found no CDN link with the webfont, but simply load the CSS like this <link rel="stylesheet" href="https://cdn.materialdesignicons.com/4.0.96/css/materialdesignicons.min.css"> .

@wernerdaehn
Copy link
Author

You are absolutely correct, this is a documentation-bug only. Yes you can specify any correctly defined font-family.
I use

n.shape = 'icon';
n.icon = {face: 'SAP-icons',
  code: '\uE0E5',
  size: 50,
  color: '#eeeeee'}

in a page where the font is defined already - within a OpenUI5 page the font is already defined, obviously - and it renders nicely.

Thomaash added a commit that referenced this issue Sep 2, 2019
It used to imply that FontAwesome and Ionicons are the only faces that
can be used. In reality these can only be used if the user ships them
themselves and others can be used too if loaded on the page.

Addresses #59.
@vis-bot
Copy link
Collaborator

vis-bot commented Sep 3, 2019

🎉 This issue has been resolved in version 5.3.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@ben-gryps
Copy link

I would like to use mui icons (Mui Icons Docs).

Any ideas how to make it work? Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers help wanted Extra attention is needed released
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants