[CDB] Linked Accounts

A place for Extension Authors to post and receive feedback on Extensions still in development. No Extensions within this forum should be used within a live environment!
Ideas Centre
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

IMPORTANT: Extensions Development rules

IMPORTANT FOR NEEDED EVENTS!!!
If you need an event for your extension please read this for the steps to follow to request the event(s)
User avatar
Flerex
Registered User
Posts: 84
Joined: Sun Oct 14, 2012 8:35 pm
Location: Galicia, Spain
Name: Flerex
Contact:

Re: [3.2][BETA] Linked Accounts

Post by Flerex » Tue Mar 13, 2018 2:20 pm

nou nou wrote:
Tue Mar 13, 2018 5:42 am
Use case to consider: I'm testing giving the Linked Accounts permission to individual users. Say account A.

Account A, having the permission, sets up a link with account B.

Account B appears in the User menu, all goes well.

Then switch to account B. Account A is now in the user menu. Click on account A to switch back and the permission error is thrown: Account B does not have the permission to link accounts.

I can think of two solutions. Either the permissions need to be given to both accounts before the link is set up. Not ideal because of a potential added admin burden. Also the extension will need to check if account B has the required permission.

Else the extension needs to somehow work if any of the linked accounts has the permission, but I don't know if that is possible.
To be honest I don't see any advantage by doing so. Right now you can link to any account (even if the latter doesn't have permissions) and you can switch to that account because you have permissions in the initial account. In account B you wouldn't be able to switch back because you don't have permissions. Maybe the best thing would be to hide the links from account B, as it doesn't have permissions.

nou nou wrote:
Tue Mar 13, 2018 5:42 am
A couple of small things. You're adding some CSS which really doesn't play well with custom styles in the dropdown menu, notably

Code: Select all

#linked_accounts {
    order: 1;
    border-top: none;
    background-color: #ECF1F3;
    margin: 5px -5px -5px -5px;
    padding: 5px 10px;
}
If you remove background-color, margin and padding it works a lot better. In fact I don't think any of it is necessary.
It is necessary to somehow separate in the UI all menu elements regarding the current account and the items that are part of the Linked Accounts for UX reasons. Right not it might not look very well in other prosilver based styles because they don't have support. I see two possibilities, either add support for the themes that need it or find another way to show the links that is more style-friendly and that doesn't clutter the interface.
nou nou wrote:
Tue Mar 13, 2018 5:42 am
Could you add a little icon to it, please, to match the other items in the menu? An icon of a link or something would be great 😀
I'm going to add the avatars of the accounts. I think it could look nice.
nou nou wrote:
Tue Mar 13, 2018 5:42 am
When installing the extension, by default it's enabled for all registered users. IMO it would be better for it to be disabled, and let admins decide who will be able to use the extension.
I don't agree with this. Having it enabled by default is the expected behavior when you install the extension. In most cases administrators will want users to use this feature when they install it. If you want to specify which groups should be able to use it I think in that case the administrator should edit permissions according to their need. If the linking permissions are disabled out of the box, permissions would have to be edited in all use cases and some administrators might even think the extension is not working.
nou nou wrote:
Tue Mar 13, 2018 5:42 am
As a feature request, would it be possible to add a way (it could be a list that lives in the ACP) for admins to see a list of all users that have linked accounts, and what those accounts are?
That's a great idea. I'll be working on it.

nou nou
Registered User
Posts: 318
Joined: Sat Oct 29, 2016 8:08 pm

Re: [3.2][BETA] Linked Accounts

Post by nou nou » Tue Mar 13, 2018 9:54 pm

Flerex wrote:
Tue Mar 13, 2018 2:20 pm
Maybe the best thing would be to hide the links from account B, as it doesn't have permissions.
Yes, sure. Or maybe do display the name in the menu alongside a :no_entry_sign:

Flerex wrote:
Tue Mar 13, 2018 2:20 pm
It is necessary to somehow separate in the UI all menu elements regarding the current account and the items that are part of the Linked Accounts for UX reasons. Right not it might not look very well in other prosilver based styles because they don't have support. I see two possibilities, either add support for the themes that need it or find another way to show the links that is more style-friendly and that doesn't clutter the interface.
Gotcha. It's not a big deal at all, really. But I do think your option 2 is best.
Flerex wrote:
Tue Mar 13, 2018 2:20 pm
I'm going to add the avatars of the accounts. I think it could look nice.
Yes, great!
Flerex wrote:
Tue Mar 13, 2018 2:20 pm
I don't agree with this. Having it enabled by default is the expected behavior when you install the extension.
Again, not a biggie, but there are plenty of extensions out there that are disabled by default and I prefer that for my workflow. I have a test board to test extensions. Once that test passes, I "release" it to a small group of users on a live forum. Only then does it go live for everyone. I've never pushed an extension any other way (well, I have when I first started using phpBB, with disastrous results...;))

Flerex wrote:
Tue Mar 13, 2018 2:20 pm
nou nou wrote:
Tue Mar 13, 2018 5:42 am
As a feature request, would it be possible to add a way (it could be a list that lives in the ACP) for admins to see a list of all users that have linked accounts, and what those accounts are?
That's a great idea. I'll be working on it.
Sweet! Looking forward to it! :)

User avatar
Flerex
Registered User
Posts: 84
Joined: Sun Oct 14, 2012 8:35 pm
Location: Galicia, Spain
Name: Flerex
Contact:

Re: [3.2][BETA] Linked Accounts

Post by Flerex » Wed Mar 14, 2018 9:34 pm

Version 0.2.0 has been released! Here is the changelog:
  • [NEW] Added a new admin interface to manage users' links (Thanks to nou nou
  • [NEW] User avatars are shown in the switching menu
  • [NEW] Translation to NL (Thanks to Solidjeuh)
  • Fixed a bug where links would be saved forever if a user was deleted
  • General Language corrections
  • Minor improvements and bugfixed
This is the new admin section:
Image
Image
Image

I'll be around to listen to your feedback!

User avatar
</Solidjeuh>
Registered User
Posts: 1538
Joined: Tue Mar 29, 2016 3:45 am
Location: Aalst (Belgium)
Name: Andy Dm
Contact:

Re: [3.2][BETA] Linked Accounts

Post by </Solidjeuh> » Wed Mar 14, 2018 10:30 pm

NL updated!
But I wont install Beta versions.. sorry. I wait for RC :)
Register a free account & Play!!
~~~ https://www.solidjeuh.be ~~~
Have a secret? --> https://www.tellyoursecrets.eu

fagbutlil
Registered User
Posts: 63
Joined: Wed Mar 07, 2018 10:56 pm

Re: [3.2][BETA] Linked Accounts

Post by fagbutlil » Thu Mar 15, 2018 12:50 am

0.2.0

Missing lang

Code: Select all

'LINKED_ACCOUNTS_LIST_CAPTION'                      => 'Linked Accounts List',
Also made the avatar smaller

Code: Select all

#linked_accounts img, #linked_accounts .avatar {
    max-height: 15px;
    width: auto;
    margin-right: 5px;
}

User avatar
</Solidjeuh>
Registered User
Posts: 1538
Joined: Tue Mar 29, 2016 3:45 am
Location: Aalst (Belgium)
Name: Andy Dm
Contact:

Re: [3.2][BETA] Linked Accounts

Post by </Solidjeuh> » Thu Mar 15, 2018 12:54 am

fagbutlil wrote:
Thu Mar 15, 2018 12:50 am
0.2.0

Missing lang

Code: Select all

'LINKED_ACCOUNTS_LIST_CAPTION'                      => 'Linked Accounts List',
Also made the avatar smaller

Code: Select all

#linked_accounts img, #linked_accounts .avatar {
    max-height: 15px;
    width: auto;
    margin-right: 5px;
}
@ Flerex, direct NL language:

Code: Select all

'LINKED_ACCOUNTS_LIST_CAPTION'                      => 'Lijst met gekoppelde accounts',
Register a free account & Play!!
~~~ https://www.solidjeuh.be ~~~
Have a secret? --> https://www.tellyoursecrets.eu

User avatar
Flerex
Registered User
Posts: 84
Joined: Sun Oct 14, 2012 8:35 pm
Location: Galicia, Spain
Name: Flerex
Contact:

Re: [3.2][BETA] Linked Accounts

Post by Flerex » Thu Mar 15, 2018 2:41 pm

Updated to 0.2.1:
  • Avatars made smaller
  • NZ translations updated
  • Missing language key found

fagbutlil
Registered User
Posts: 63
Joined: Wed Mar 07, 2018 10:56 pm

Re: [3.2][BETA] Linked Accounts

Post by fagbutlil » Thu Mar 15, 2018 9:14 pm

Flerex wrote:
Thu Mar 15, 2018 2:41 pm
Updated to 0.2.1:
  • Avatars made smaller
  • NZ translations updated
  • Missing language key found

Much better looking now :lol:

nou nou
Registered User
Posts: 318
Joined: Sat Oct 29, 2016 8:08 pm

Re: [3.2][BETA] Linked Accounts

Post by nou nou » Fri Mar 16, 2018 2:24 am

Terrific stuff!

I found one small bug. When you have multiple accounts linked, the list in the navbar header profile menu can overlap with other entries.

You can fix it in navbar_header_profile_list_after.html like this:

Code: Select all

{% if switchable_account %}
{% INCLUDECSS '@flerex_linkedaccounts/linkedaccounts.css' %}
<ul id="linked_accounts">
		{% for account in switchable_account %}
		<li><a href="{{ account.SWITCH_LINK }}">{{ account.AVATAR }}{{ account.NAME }}</a></li>
		{% endfor %}
</ul>
{% endif %}
And one small (hopefully) feature request. It would be great if the hidden status of an account transfers through switching, and to have that as a UCP "inherit hidden status" option. So if set, and user A has a hidden session and switches to user B, user B would be hidden as well.

Thanks!

User avatar
Flerex
Registered User
Posts: 84
Joined: Sun Oct 14, 2012 8:35 pm
Location: Galicia, Spain
Name: Flerex
Contact:

Re: [3.2][BETA] Linked Accounts

Post by Flerex » Fri Mar 16, 2018 10:31 am

nou nou wrote:
Fri Mar 16, 2018 2:24 am
Terrific stuff!

I found one small bug. When you have multiple accounts linked, the list in the navbar header profile menu can overlap with other entries.

You can fix it in navbar_header_profile_list_after.html like this:

Code: Select all

{% if switchable_account %}
{% INCLUDECSS '@flerex_linkedaccounts/linkedaccounts.css' %}
<ul id="linked_accounts">
		{% for account in switchable_account %}
		<li><a href="{{ account.SWITCH_LINK }}">{{ account.AVATAR }}{{ account.NAME }}</a></li>
		{% endfor %}
</ul>
{% endif %}
And one small (hopefully) feature request. It would be great if the hidden status of an account transfers through switching, and to have that as a UCP "inherit hidden status" option. So if set, and user A has a hidden session and switches to user B, user B would be hidden as well.

Thanks!
I can't replicate the bug you're talking about. When there're multiple accounts linked a scrollbar appears. Could you give some more details?

About your feature request. I kinda see it as a bug, so I fixed it without allowing users to change the behavior. If in the future there're more possibilities to user configuration I'd add all of this to a new section in the UCP, but right not I don't think creating a new section for just one setting is the best idea.

Version 0.2.2 released. Changelog:
  • If account A had autologin activated, it will now be propagated to account B
  • If account A were hidden, its status would now be propagated to account B
Edited: Version 0.2.3 has been released. With this version the extension developement status moves to RC. If no more bugs are found, I will try to publish it into the Extension DB.

Changelog for 0.2.3:
  • [NEW] Native-like error management in the UCP module
  • Extension DB ready
  • Code improvements

Miri4ever
Registered User
Posts: 409
Joined: Sat Mar 07, 2015 11:18 am

Re: [3.2][RC] Linked Accounts

Post by Miri4ever » Fri Mar 16, 2018 4:16 pm

Working nice as far I can say for the moment. I just needed to remove the background color from CSS and see no problems with the styles I use so far. Creating colors not used from PHPBB itself is often a problem because nobody knows what kind of colors users need. But the rest working well with the switches as I see.
Homepage: Terra Oceanica

User avatar
Flerex
Registered User
Posts: 84
Joined: Sun Oct 14, 2012 8:35 pm
Location: Galicia, Spain
Name: Flerex
Contact:

Re: [3.2][RC] Linked Accounts

Post by Flerex » Fri Mar 16, 2018 4:38 pm

I just added a tiny modification that should maximize compatibility with prosilver-based themes that are not directly supported by the extension. This change will be available with the next release of the extension. Even though this modification solves the problem with the background color, unsupported themes will still potentially have compatibility problems with the extension.

This kind of problems, as far as I know, will happen in any extension that had to implement a custom interface, just like Linked Accounts does with the switching menu. The official phpBB statement on this kind of issues is that if a style wants to support the extension, the style author should contact with me so I can add the correct style files to the official package of the extension. There's also the possibility where the style files are put directly into the extension once downloaded without having to release it in the public. This is pretty common in custom private styles.

As I said in a previous message, I am not going to remove the custom CSS of this menu because it would be a bad UI design, because there's to make some distinction between what are the current account menu options and what is part of the account switching system. What I can do is to change the way the switching feature is presented to the user, as long as the change is an improvement and is a good choice in UI/UX. I took some inspiration from how Tumblr differenciates the account-related stuff from the different blogs a user has. Like this:

Image

If you think there's a better way to approach this design problem. I'm open to any suggestion.

nou nou
Registered User
Posts: 318
Joined: Sat Oct 29, 2016 8:08 pm

Re: [3.2][BETA] Linked Accounts

Post by nou nou » Sat Mar 17, 2018 4:45 am

Flerex wrote:
Fri Mar 16, 2018 10:31 am
I can't replicate the bug you're talking about. When there're multiple accounts linked a scrollbar appears. Could you give some more details?
Sure. I have another extension called "notes" that adds a menu item, and when I use your extension with 2 linked accounts the menu looks like this:


Image


After applying my fix:


Image


Thanks for all the other additions and fixes, though - the extension works perfect for me now!

Miri4ever
Registered User
Posts: 409
Joined: Sat Mar 07, 2015 11:18 am

Re: [3.2][RC] Linked Accounts

Post by Miri4ever » Sat Mar 17, 2018 7:52 am

Getting the background used in prosilver is now working the way it should work. Nice fix.

@nou nou:

I see a little small avatar image so I not noticed that this extension produce no Fontawesome Icon in front of the user name. For people with no Avatar the design with no icon before could looking weired and not looking so nice if the username is moved to the left site from this menu. Your example showing this very well.

Maybe a nice switch icon before the name and the style would looking more perfect.
Homepage: Terra Oceanica

User avatar
Flerex
Registered User
Posts: 84
Joined: Sun Oct 14, 2012 8:35 pm
Location: Galicia, Spain
Name: Flerex
Contact:

Re: [3.2][RC] Linked Accounts

Post by Flerex » Sat Mar 17, 2018 6:46 pm

Version 0.2.4 released. Changelog:

  • Placeholder avatar when the user doesn't have one
  • Compatibility with prosilver-based themes improved
  • General code improvements

Locked

Return to “Extensions in Development”