solved Arrange Sprite Icons

Dazed
Dazed
@dazed
11 years ago
1,022 posts
Out of curiosity, since there is now a great easy way to arrange the sprite order, if I need to add a sprite, how do I get it so that it appears in the arrange area?
updated by @dazed: 03/03/14 02:05:13PM
brian
@brian
11 years ago
10,148 posts
Dazed:
Out of curiosity, since there is now a great easy way to arrange the sprite order, if I need to add a sprite, how do I get it so that it appears in the arrange area?

I'm not sure what you - what's the arrange area?

Thanks!


--
Brian Johnson
Founder and Lead Developer - Jamroom
https://www.jamroom.net
Dazed
Dazed
@dazed
11 years ago
1,022 posts
The small icons on most pages where the administration can change the order of the sprite icons like add, delete and update.
brian
@brian
11 years ago
10,148 posts
Yeah that's what I am asking - how are you changing the order, and what order do you mean? Sorry I'm just not following you here...


--
Brian Johnson
Founder and Lead Developer - Jamroom
https://www.jamroom.net
Dazed
Dazed
@dazed
11 years ago
1,022 posts
Hey Brian - You actually mentioned this to me a few weeks back. So on the audio page where you have the bundle, playlist, trash can, gear etc. If you login as the admin there is another button there so you can rearrange that order if you wanted playlist first, then bundle etc.

I added a new option on my playlist (item_list.tpl) page and added another sprite. However I do not know what page it really needs to go on so it appears in the admin config function so I can change the order. When I click the admin config button on the playlist page it takes me to site_name/core/item_action_buttons/list/m=jrPlaylist. In the template all I see is the below. I thought it was in playlist_button.tpl but that does not look right.

 <div class="block_config">
                        {jrCore_item_list_buttons module="jrPlaylist" item=$item}
brian
@brian
11 years ago
10,148 posts
Ahh - sorry I thought you were talking about arranging the images in the sprite background used in the CSS.

You cannot add a button into the core "control" by simply placing it in the template - that can only be done at the module level.

However, you can always just add your button in before/after the code - so this:

<div class="block_config">
    {jrCore_item_list_buttons module="jrPlaylist" item=$item}
</div>

becomes:

<div class="block_config">
    <a href="{$jamroom_url}/whatever">{jrCore_icon icon="start"}</a>
    {jrCore_item_list_buttons module="jrPlaylist" item=$item}
</div>

and the "star" icon would appear to the left of the existing buttons. Modify it to suit your needs.

Hope this helps!


--
Brian Johnson
Founder and Lead Developer - Jamroom
https://www.jamroom.net
Dazed
Dazed
@dazed
11 years ago
1,022 posts
Thanks Brian. I was wanted to stay consistent so I thought I would add it into the core. Is that a difficult process? I could not find the template it was on.
brian
@brian
11 years ago
10,148 posts
Dazed:
Thanks Brian. I was wanted to stay consistent so I thought I would add it into the core. Is that a difficult process? I could not find the template it was on.

You would have to create your own custom module and register the proper functions to add the action button in for core support - it's more complicated than editing a template, so I'd recommend just editing the template :)


--
Brian Johnson
Founder and Lead Developer - Jamroom
https://www.jamroom.net
SteveX
SteveX
@ultrajam
11 years ago
2,584 posts
Is there a description anywhere of this new feature?

I have a custom module which no longer works correctly with the old buttons (the buttons are there and work, but the icon doesn't appear, the button is empty).

I tried the new way, but the icons don't appear there either, and the update and delete buttons don't appear at all.

It could be only admin that the buttons don't appear for.

Thanks


--
¯\_(ツ)_/¯ Education, learning resources, TEL, AR/VR/MR, CC licensed content, panoramas, interactive narrative, sectional modules (like jrDocs), lunch at Uni of Bristol. Get in touch if you share my current interests or can suggest better :)

updated by @ultrajam: 01/29/14 02:49:23AM
SteveX
SteveX
@ultrajam
11 years ago
2,584 posts
Yes, it seems to be only the admin user who sees this. The buttons work, but no icons appear. All other modules seem fine, so it is something I've coded wrongly but can't see what it could be.

Has anyone seen this before for an admin user?
broken-buttons.png
broken-buttons.png  •  11KB




--
¯\_(ツ)_/¯ Education, learning resources, TEL, AR/VR/MR, CC licensed content, panoramas, interactive narrative, sectional modules (like jrDocs), lunch at Uni of Bristol. Get in touch if you share my current interests or can suggest better :)

updated by @ultrajam: 01/29/14 10:22:01AM
brian
@brian
11 years ago
10,148 posts
What are you using for the button images? Are you using a sprite icon?


--
Brian Johnson
Founder and Lead Developer - Jamroom
https://www.jamroom.net
SteveX
SteveX
@ultrajam
11 years ago
2,584 posts
Yes, I just noticed that the sprite icons stylesheet isn't being included for the admin user, whihc is why the sprite isn't showing.

I havn't noticed anywhere to customise that, so haven't got a clue why it isn't including the stylesheet for admin.


--
¯\_(ツ)_/¯ Education, learning resources, TEL, AR/VR/MR, CC licensed content, panoramas, interactive narrative, sectional modules (like jrDocs), lunch at Uni of Bristol. Get in touch if you share my current interests or can suggest better :)
brian
@brian
11 years ago
10,148 posts
SteveX:
Yes, I just noticed that the sprite icons stylesheet isn't being included for the admin user, whihc is why the sprite isn't showing.

I havn't noticed anywhere to customise that, so haven't got a clue why it isn't including the stylesheet for admin.

I've not seen that before when working on stuff on this end. The CSS style will be included on the first call to a sprite on a page. Do you see the CSS URL to include the CSS in the HTML source?


--
Brian Johnson
Founder and Lead Developer - Jamroom
https://www.jamroom.net
SteveX
SteveX
@ultrajam
11 years ago
2,584 posts
I do when logged in as the profile owner, but not as the main admin.

{$flag = jrCore_get_flag("jrcore_include_icon_css_32")}{debug}
That shows $flag as being false both before and after the profile_header.tpl buttons


--
¯\_(ツ)_/¯ Education, learning resources, TEL, AR/VR/MR, CC licensed content, panoramas, interactive narrative, sectional modules (like jrDocs), lunch at Uni of Bristol. Get in touch if you share my current interests or can suggest better :)
brian
@brian
11 years ago
10,148 posts
Hmm... I think if there was an issue with this not showing to admins I'd see it immediately from one of my sites, or here on Jamroom.net, so I don't think that is it. What skin are you using and testing this with?

Thanks!


--
Brian Johnson
Founder and Lead Developer - Jamroom
https://www.jamroom.net
SteveX
SteveX
@ultrajam
11 years ago
2,584 posts
I'm sure it will be something in my code, I haven't seen this any where else either.

It's a skin based on Nova, but it happens in jrElastic as well, so definitely a "my module" thing. I'll go through it again tomorrow, maybe I'll find it with fresh eyes.


--
¯\_(ツ)_/¯ Education, learning resources, TEL, AR/VR/MR, CC licensed content, panoramas, interactive narrative, sectional modules (like jrDocs), lunch at Uni of Bristol. Get in touch if you share my current interests or can suggest better :)
SteveX
SteveX
@ultrajam
11 years ago
2,584 posts
Well I eventually traced this to a missing "." $content = instead of $content .=

But it is still baffling - I can see nothing in my code which would make this happen to the admin and no other account!

Still, a fix is a fix (for now). A typo "."
Where is the "bangs head against the wall" smiley? :)

Thanks Brian, and sorry for extending your thread Dazed.


--
¯\_(ツ)_/¯ Education, learning resources, TEL, AR/VR/MR, CC licensed content, panoramas, interactive narrative, sectional modules (like jrDocs), lunch at Uni of Bristol. Get in touch if you share my current interests or can suggest better :)
michael
@michael
11 years ago
7,772 posts
I've seen that before. The sort-of-but-not-really icons. Usually goes away after clearing the caches for me though.

--edit--
these are the smileys (screenshot)
screenshot_smileys.png


updated by @michael: 01/29/14 04:47:10PM
michael
@michael
11 years ago
7,772 posts
Here are the updated docs on item action buttons including how to add one via a module for developers:

"Item Action Buttons"
https://www.jamroom.net/the-jamroom-network/documentation/development/1508/item-action-buttons
SteveX
SteveX
@ultrajam
11 years ago
2,584 posts
Great Docs Michael! Thanks!!! :)

Quote: these are the smileys (screenshot)

That screenshot would look better underneath the modal though ;)

I did clear the caches many, many more times than could ever be necessary.


--
¯\_(ツ)_/¯ Education, learning resources, TEL, AR/VR/MR, CC licensed content, panoramas, interactive narrative, sectional modules (like jrDocs), lunch at Uni of Bristol. Get in touch if you share my current interests or can suggest better :)

updated by @ultrajam: 01/29/14 06:33:41PM
michael
@michael
11 years ago
7,772 posts
SteveX:...That screenshot would look better underneath the modal though ;) ...

sorry, not understanding. what would look better where?
SteveX
SteveX
@ultrajam
11 years ago
2,584 posts
I'm not a fan of the smileys. I'd decrease their z-index a lot, or make them more subtle.

ᕙ༼ຈل͜ຈ༽ᕗ


--
¯\_(ツ)_/¯ Education, learning resources, TEL, AR/VR/MR, CC licensed content, panoramas, interactive narrative, sectional modules (like jrDocs), lunch at Uni of Bristol. Get in touch if you share my current interests or can suggest better :)