Certain icons from aui-experimental-iconfont aren't loaded.

I define the com.atlassian.auiplugin:aui-experimental-iconfont in atlassian-plugin.xml to use some default JIRA icons. However some icons aren't loaded, like aui-iconfont-remove-label or aui-iconfont-edit. In JIRA 6 all icons are loaded successfully but in JIRA 5 just some of them.

Any solution or suggestion?

3 answers

1 accepted

Accepted Answer
2 votes
Sean Curtis Atlassian Team Jul 07, 2013

Hi Diogo,

The iconfont is a brand new component and we're adding icons to it constantly. I'm guessing the icon you are after isn't in the iconfont bundled with the version of JIRA you're looking at. If you really need access to the icon you can run the risk of backporting the iconfont from a newer version of AUI. If you do this you'll need to do the following:

  1. Download the latest version of AUI.
  2. Copy the iconfont files out and rename them namespaced to your plugin, eg fooplugin-atlassian-iconfont.ttf
  3. Copy the iconfont css file
  4. Rename the font-face declaration so that the font family is "Fooplugin Atlassian Icons"
  5. Change all the class names to be prefixed with your plugin namespace like the font files, fooplugin-aui-iconfont-edit
  6. Change the font-family in this new iconfont css file to point to your newly created font.
  7. Provide that CSS file, and the font files in your plugin

You're essentially backporting the font and namespacing it to your plugin. Ensure you do change all the namespaces otherwise you will run the risk of breaking icons used in JIRA or other plugins. You can use conditions to ensure this backported CSS file is only included when you're running a particular version of JIRA (eg unecessary in JIRA 6).

Hope this helps.

Sean

@Sean

Im trying to get sortable table running in JIRA 5.1 according to this documentation

Ive defined in atlassian-plugin.xml web-resource section of my plugin

<dependency>com.atlassian.auiplugin:aui-experimental-table-sortable</dependency>

then in velocity template

${webResourceManager.requireResourcesForContext("my-plugin-resource-key")}

all my resources (css, js, images) are getting loaded, but the webResourceManager complains that it can't find the reousrce for sortable table.

[atlassian.plugin.webresource.DefaultResourceDependencyResolver] Cannot find web resource module for: com.atlassian.auiplugin:aui-experimental-table-sortable

Do you have a clue why?

Sean Curtis Atlassian Team Mar 02, 2014

Alexej,

JIRA 5.1 didn't ship with AUI 5.1 - it comes with AUI 3.7 which doesn't contain the sortable table component. You'll need a more recent version of JIRA in order to get that (6.1 probably).

Alternatively you can grab the files from AUI and "backport" them by including them in your plugin. This can be risky and may not have all the required dependencies.

Hope this helps.

Sean

@Sean Curtis

JIRA 5.1 didn't ship with AUI 5.1 - it comes with AUI 3.7 which doesn't contain the sortable table component.

Ah, i see. This is quite confusing, AUI Documentation says available since 5.1. One might easily think that its refering to JIRA Version.

You'll need a more recent version of JIRA in order to get that (6.1 probably).

Well, our customer is using JIRA 5.1, we cannot migrate to 6.1 right away just to get the tables sortable.

Alternatively you can grab the files from AUI and "backport" them by including them in your plugin. This can be risky and may not have all the required dependencies.

Hope this helps.

This is intresting. Are you saying, that it might be possible to have sortable tables working in JIRA 5.1 anyway by upgrading AUI withing the scope of the plugin? Did i undestrand you right, all you have to do is to copy the AUI files in your own plugin? How can i find out which files are required for that?

0 votes
Sean Curtis Atlassian Team Jul 07, 2013

Hi Diogo,

The iconfont is a brand new component and we're adding icons to it constantly. I'm guessing the icon you are after isn't in the iconfont bundled with the version of JIRA you're looking at. If you really need access to the icon you can run the risk of backporting the iconfont from a newer version of AUI. If you do this you'll need to do the following:

  1. Download the latest version of AUI.
  2. Copy the iconfont files out and rename them namespaced to your plugin, eg fooplugin-atlassian-iconfont.ttf
  3. Copy the iconfont css file
  4. Rename the font-face declaration so that the font family is "Fooplugin Atlassian Icons"
  5. Change all the class names to be prefixed with your plugin namespace like the font files, fooplugin-aui-iconfont-edit
  6. Change the font-family in this new iconfont css file to point to your newly created font.
  7. Provide that CSS file, and the font files in your plugin

You're essentially backporting the font and namespacing it to your plugin. Ensure you do change all the namespaces otherwise you will run the risk of breaking icons used in JIRA or other plugins. You can use conditions to ensure this backported CSS file is only included when you're running a particular version of JIRA (eg unecessary in JIRA 6).

Hope this helps.

Sean

Hii @Sean Curtis,

I want to use "Font Awesome Icons" in my plugin.Can you please tell me where to copy the iconfont files(ttf,woff,eot) in my plugin. & how to call that files in css.

I tried the same by putting all those font files inside font folder & putting the font folder in CSS folder

but it is throwing foll error.

GET http://localhost:1990/confluence/s/en_GB-1988229788/4732/NOCACHE1/2…es/myPlugin:icon-editor/fonts/fontawesome-webfont.woff?v=4.0.3404 (Not Found):1990/confluence/s/en_GB-1988229788/4732/NOCACHE1/2.0.1/_/download/resources/myPlugin:icon-editor/fonts/fontawesome-webfont.woff?v=4.0.3:

Thanks.

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Sep 18, 2018 in Jira

What modern development practices are at the heart of how your team delivers software?

Hey Community mates! Claire here from the Software Product Marketing team. We all know software development changes rapidly, and it's often tough to keep up. But from our research, we've found the h...

24,964 views 2 7
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you