Skip to content

Commit

Permalink
preparing next release
Browse files Browse the repository at this point in the history
  • Loading branch information
roncodes committed May 30, 2024
1 parent 6b11bf9 commit 9acee7a
Show file tree
Hide file tree
Showing 12 changed files with 572 additions and 350 deletions.
21 changes: 17 additions & 4 deletions addon/components/modals/group-form.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,24 @@

<div class="input-group">
<div class="mb-4">
<InputLabel class="mb-2" @labelText={{t "iam.components.modals.group-form.select-users-add-group"}} @helpText={{t "iam.components.modals.group-form.search-select-users-add-group"}} />
<InputLabel
class="mb-2"
@labelText={{t "iam.components.modals.group-form.select-users-add-group"}}
@helpText={{t "iam.components.modals.group-form.search-select-users-add-group"}}
/>

<div class="flex items-start justify-between">
<ModelSelect @modelName="user" @selectedModel={{@options.lastSelectedUser}} @placeholder={{t "iam.components.modals.group-form.select-user-add-group"}} class="w-64" @triggerClass="form-select form-input" @infiniteScroll={{false}} @renderInPlace={{true}} @onChange={{@options.addUser}} as |model|>
<ModelSelect
@modelName="user"
@selectedModel={{@options.lastSelectedUser}}
@placeholder={{t "iam.components.modals.group-form.select-user-add-group"}}
class="w-64"
@triggerClass="form-select form-input"
@infiniteScroll={{false}}
@renderInPlace={{true}}
@onChange={{@options.addUser}}
as |model|
>
{{model.name}}
</ModelSelect>
</div>
Expand All @@ -32,8 +46,7 @@
{{user.name}}
</span>
<span>
<a href="javascript:;" class="text-blue-300 no-underline hover:text-blue-500" {{on "click" (fn
@options.removeUser user)}}>
<a href="javascript:;" class="text-blue-300 no-underline hover:text-blue-500" {{on "click" (fn @options.removeUser user)}}>
<FaIcon @icon="times" @prefix="fas" />
</a>
</span>
Expand Down
2 changes: 1 addition & 1 deletion addon/components/modals/policy-form.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
</div>
<div class="input-group">
<label>
{{t "iam.components.modals.policy-form.select-permissions"}}
{{t "iam.components.modals.policy-form.select-permissions"}}
</label>
<PermissionPicker @selected={{@options.policy.permissions}} @onChange={{fn (mut @options.policy.permissions)}} />
</div>
Expand Down
7 changes: 6 additions & 1 deletion addon/components/modals/user-form.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,12 @@
<label>
{{t "iam.common.country"}}
</label>
<CountrySelect class="w-full form-input form-select form-datalist" @value={{@options.user.country}} @onChange={{fn (mut @options.user.country)}} placeholder={{t "iam.common.country"}} />
<CountrySelect
class="w-full form-input form-select form-datalist"
@value={{@options.user.country}}
@onChange={{fn (mut @options.user.country)}}
placeholder={{t "iam.common.country"}}
/>
</div>
</div>
</div>
Expand Down
10 changes: 8 additions & 2 deletions addon/components/permission-picker.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,12 @@
<div class="mb-2 flex items-center justify-between">
<div class="flex items-center">
<div class="permission-picker-search">
<Input @type="text" {{on "input" (perform this.search)}} placeholder={{t "iam.components.permission-picker.search-permissions-keyword"}} class="w-64 form-input form-input-sm" />
<Input
@type="text"
{{on "input" (perform this.search)}}
placeholder={{t "iam.components.permission-picker.search-permissions-keyword"}}
class="w-64 form-input form-input-sm"
/>
</div>
<div>
{{#if this.isLoading}}
Expand All @@ -13,7 +18,8 @@
</div>
</div>
<div class="text-sm dark:text-gray-100">
{{t "iam.components.permission-picker.selected"}} {{this.selected.length}}
{{t "iam.components.permission-picker.selected"}}
{{this.selected.length}}
</div>
</div>
<div class="bg-white border border-gray-200 rounded shadow-sm dark:bg-gray-700 dark:border-gray-900 text-xs">
Expand Down
6 changes: 5 additions & 1 deletion addon/components/table/cell/group-members.hbs
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
<div class="flex flex-row items-center space-x-2">
{{#each @row.users as |user|}}
<div class="rounded-lg shadow-sm border border-blue-800 bg-blue-600 hover:bg-blue-500 text-white">
<a href="javascript:;" class="truncate inline-flex items-center px-2 py-0.5 rounded-lg text-xs font-medium text-white leading-4 whitespace-no-wrap" {{on "click" (fn @column.onClick user @row)}}>
<a
href="javascript:;"
class="truncate inline-flex items-center px-2 py-0.5 rounded-lg text-xs font-medium text-white leading-4 whitespace-no-wrap"
{{on "click" (fn @column.onClick user @row)}}
>
{{user.name}}
</a>
</div>
Expand Down
4 changes: 2 additions & 2 deletions addon/components/table/cell/user-name.hbs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<div class="relative flex items-center">
<img src={{@row.avatar_url}} alt={{@row.name}} class="w-6 h-6 rounded-md {{if @column.hasOnline "mx-2" "mr-2"}}" />
<img src={{@row.avatar_url}} alt={{@row.name}} class="w-6 h-6 rounded-md {{if @column.hasOnline 'mx-2' 'mr-2'}}" />
<span class="relative block">
<a href="javascript:;" class="relative block" {{on "click" this.onClick}}>
{{#if (has-block)}}
Expand All @@ -12,6 +12,6 @@
</a>
</span>
{{#if @column.showOnlineIndicator}}
<FaIcon @icon="circle" class="absolute left-0 top-0 {{if @row.online "text-green-500" "text-yellow-200"}}" />
<FaIcon @icon="circle" class="absolute left-0 top-0 {{if @row.online 'text-green-500' 'text-yellow-200'}}" />
{{/if}}
</div>
14 changes: 12 additions & 2 deletions addon/templates/groups/index.hbs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<Layout::Section::Header @title={{t "iam.common.group"}} @searchQuery={{this.query}} @onSearch={{perform this.search}}>
{{#if (safe-has this.table "selectedRows")}}
{{#if (safe-has this.table "selectedRows")}}
<DropdownButton @icon="layer-group" @text={{t "iam.common.bulk-action"}} @type="magic" @size="sm" @buttonWrapperClass="mr-2" @contentClass="dropdown-menu" as |dd|>
<div class="next-dd-menu mt-2 mx-0">
<div class="px-1">
Expand All @@ -15,7 +15,17 @@
</Layout::Section::Header>

<Layout::Section::Body>
<Table @rows={{@model}} @columns={{this.columns}} @selectable={{true}} @canSelectAll={{true}} @onSetup={{fn (mut this.table)}} @pagination={{true}} @paginationMeta={{@model.meta}} @page={{this.page}} @onPageChange={{fn (mut this.page)}} @tfootVerticalOffset="53" @tfootVerticalOffsetElements=".next-view-section-subheader" />
<Table
@rows={{@model}}
@columns={{this.columns}}
@selectable={{true}}
@canSelectAll={{true}}
@onSetup={{fn (mut this.table)}}
@pagination={{true}}
@paginationMeta={{@model.meta}}
@page={{this.page}}
@onPageChange={{fn (mut this.page)}}
/>
</Layout::Section::Body>

{{outlet}}
14 changes: 12 additions & 2 deletions addon/templates/policies/index.hbs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<Layout::Section::Header @title={{t "iam.policies.index.title"}} @searchQuery={{this.query}} @onSearch={{perform this.search}}>
{{#if (safe-has this.table "selectedRows")}}
{{#if (safe-has this.table "selectedRows")}}
<DropdownButton @icon="layer-group" @text={{t "iam.common.bulk-action"}} @type="magic" @size="sm" @buttonWrapperClass="mr-2" @contentClass="dropdown-menu" as |dd|>
<div class="next-dd-menu mt-2 mx-0">
<div class="px-1">
Expand All @@ -14,7 +14,17 @@
</Layout::Section::Header>

<Layout::Section::Body>
<Table @rows={{@model}} @columns={{this.columns}} @selectable={{true}} @canSelectAll={{true}} @onSetup={{fn (mut this.table)}} @pagination={{true}} @paginationMeta={{@model.meta}} @page={{this.page}} @onPageChange={{fn (mut this.page)}} @tfootVerticalOffset="53" @tfootVerticalOffsetElements=".next-view-section-subheader" />
<Table
@rows={{@model}}
@columns={{this.columns}}
@selectable={{true}}
@canSelectAll={{true}}
@onSetup={{fn (mut this.table)}}
@pagination={{true}}
@paginationMeta={{@model.meta}}
@page={{this.page}}
@onPageChange={{fn (mut this.page)}}
/>
</Layout::Section::Body>

{{outlet}}
14 changes: 12 additions & 2 deletions addon/templates/roles/index.hbs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<Layout::Section::Header @title={{t "iam.common.role"}} @searchQuery={{this.query}} @onSearch={{perform this.search}}>
{{#if (safe-has this.table "selectedRows")}}
{{#if (safe-has this.table "selectedRows")}}
<DropdownButton @icon="layer-group" @text={{t "iam.common.bulk-action"}} @type="magic" @size="sm" @buttonWrapperClass="mr-2" @contentClass="dropdown-menu" as |dd|>
<div class="next-dd-menu mt-2 mx-0">
<div class="px-1">
Expand All @@ -14,7 +14,17 @@
</Layout::Section::Header>

<Layout::Section::Body>
<Table @rows={{@model}} @columns={{this.columns}} @selectable={{true}} @canSelectAll={{true}} @onSetup={{fn (mut this.table)}} @pagination={{true}} @paginationMeta={{@model.meta}} @page={{this.page}} @onPageChange={{fn (mut this.page)}} @tfootVerticalOffset="53" @tfootVerticalOffsetElements=".next-view-section-subheader" />
<Table
@rows={{@model}}
@columns={{this.columns}}
@selectable={{true}}
@canSelectAll={{true}}
@onSetup={{fn (mut this.table)}}
@pagination={{true}}
@paginationMeta={{@model.meta}}
@page={{this.page}}
@onPageChange={{fn (mut this.page)}}
/>
</Layout::Section::Body>

{{outlet}}
2 changes: 0 additions & 2 deletions addon/templates/users/index.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,6 @@
@paginationMeta={{@model.meta}}
@page={{this.page}}
@onPageChange={{fn (mut this.page)}}
@tfootVerticalOffset="53"
@tfootVerticalOffsetElements=".next-view-section-subheader"
/>
</Layout::Section::Body>

Expand Down
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@fleetbase/iam-engine",
"version": "0.0.11",
"version": "0.0.12",
"description": "Fleetbase IAM extension provides identity and access management module for managing users, permissions and policies.",
"fleetbase": {
"route": "iam",
Expand Down Expand Up @@ -42,8 +42,8 @@
"publish:github": "npm config set '@fleetbase:registry' https://npm.pkg.github.com/ && npm publish"
},
"dependencies": {
"@fleetbase/ember-core": "^0.2.10",
"@fleetbase/ember-ui": "^0.2.15",
"@fleetbase/ember-core": "^0.2.11",
"@fleetbase/ember-ui": "^0.2.16",
"@babel/core": "^7.23.2",
"ember-cli-babel": "^8.2.0",
"ember-cli-htmlbars": "^6.3.0",
Expand Down
Loading

0 comments on commit 9acee7a

Please sign in to comment.