国旗

Yep, it’s fixed :+1:

Really great to see the improvements made here, everyone.
Really awesome!

Click on mobile? Where is this again?

You’re close! Click Edit CSS/HTML, editing the mobile styling is one of the tabs in there.

4 个赞

Jeff Thanks for updating did you find it Dylan?

Is it possible to use that plugin with other images except flags?

Solution: It is possible to edit flaglist.js.es6 file

{
      "name": "fo",
      "value": "fo.png"
    }

How you can add string variables? What is the user-inputted location?

Solution: I forked plugin repo and customize for my purpose. It seems work.

With that fix, the flag is displayed to the left of the user’s name. How do I move it to the right of the name?

2 个赞

I was added “url” to that component in flaglist.js.es6 file:

{
      "name": "name",
      "value": "name.png",
      "url": "name-link"
    }

How can I print the URL value in show-user-card.hbs?

{{model.custom_fields.nationalflag_iso.url}}

Nice plugin indeed!

I have problem, when i go to user options, and select flag…click SAVE, when i refresh it wont save it it goes back to default.

Any clue why? :slight_smile:

p.s. i did full system and discourse backup this morning, could that be the problem?

Thanks

This was caused by a recent change in Discourse. It will require a small change to the plugin to fix the problem.

@Ebs I have made a pull request on your repository with the change: FIX: Update for changes to Discourse core by davidtaylorhq · Pull Request #3 · Ebsy/discourse-nationalflags · GitHub

4 个赞

Thank you i was confused :slight_smile: @david

Merged. Thanks a lot!

3 个赞

Problem solved, i can save national flag now!

Thanks @david and @Ebs

Small issue regarding style/alignment with the mobile view of discourse. The national flag seems to be stretched vertically and is aligned above the username. Would it be possible to move the alignment of the icon to the right of the username/title (to coincide with the respective placement on the desktop view) and fix the distortion?

Desktop:

Mobile:

Please note that the only thing that was done was clicking on the view toggle link in the hamburger menu.

1 个赞

I second this. Please help, looks ugly on mobile…

Thought it was about time I fixed it :smiley:
Just updated the plugin. flag is now after the username on mobile (and not stretched anymore) :+1:

3 个赞

嘿 Neil @Ebs

正如我们讨论过的,我已提交 PR,为你的优秀插件添加一些额外功能!

抢先预览:

自然语言描述与搜索

替换代码——顺便提一下,代码中仍在使用这些代码,但已隐藏:

:arrow_right:

自定义向导插件支持

如果你同时使用这两个插件,就可以在向导中加入国旗更新步骤,例如供新用户或现有用户完善个人资料时使用。

一些需要考虑的事项

对于非标准代码,有几个描述需要在 .yml 文件中进行修正。这部分我留给你处理,因为你最清楚每个代码的含义 :slight_smile:

现在已具备为英语以外的其他语言添加本地化文本的结构基础。

如果你有任何意见,请告诉我。

合并后也请告知我,因为之后不久我需要发布一次新的自定义向导更新。

@angus

7 个赞

FYI 我已推送了一个小更新来优化代码(感谢 @angus 的建议)

4 个赞

感谢合并,@Ebs

@Vikas_Dangi,下拉菜单现在使用描述文本了。

3 个赞