Skip to content

Commit

Permalink
release new version
Browse files Browse the repository at this point in the history
  • Loading branch information
markus-ebner committed Mar 31, 2021
1 parent c5de975 commit 178c6b7
Show file tree
Hide file tree
Showing 7 changed files with 52 additions and 45 deletions.
64 changes: 32 additions & 32 deletions documentation.json
Original file line number Diff line number Diff line change
Expand Up @@ -3758,7 +3758,7 @@
"assetsDirs": [],
"styleUrlsData": [
{
"data": ":host {\n box-sizing: border-box;\n .result-entry {\n box-sizing: border-box;\n display: flex;\n flex-direction: column;\n height: 100%;\n .mat-card-image {\n object-fit: cover;\n max-height: 350px;\n }\n mat-chip {\n height: auto;\n width: min-content;\n white-space: nowrap;\n }\n .subtitle-container {\n display: flex;\n align-items: center;\n flex-wrap: wrap;\n mat-icon:not(:first-child) {\n margin-left: 5px;\n }\n }\n mat-card-content {\n overflow: hidden;\n text-wrap: none;\n text-overflow: ellipsis;\n }\n mat-card-actions {\n display: flex;\n flex: 1 0 auto;\n align-items: flex-end;\n }\n mat-icon.mat-card-avatar {\n width: 40px;\n height: 40px;\n font-size: 40px;\n color: var(--accent-color);\n }\n .show-more-text {\n margin-top: -70px;\n background: rgb(255, 255, 255);\n background: linear-gradient(\n rgba(255, 255, 255, 0.1) 0%,\n rgba(255, 255, 255, 0.3) 10%,\n rgba(255, 255, 255, 0.5) 20%,\n rgba(255, 255, 255, 0.8) 30%,\n rgba(255, 255, 255, 1) 100%\n );\n text-align: center;\n padding: 10px 25px;\n backdrop-filter: blur(1px);\n }\n .show-more-open {\n margin-top: -10px;\n padding: 10px;\n }\n }\n}\n",
"data": ":host {\n box-sizing: border-box;\n .result-entry {\n box-sizing: border-box;\n display: flex;\n flex-direction: column;\n height: 100%;\n .mat-card-image {\n object-fit: cover;\n max-height: 350px;\n }\n mat-chip {\n height: auto;\n width: min-content;\n white-space: nowrap;\n }\n .subtitle-container {\n display: flex;\n align-items: center;\n flex-wrap: wrap;\n mat-icon {\n margin-right: 5px;\n &:not(:first-child) {\n margin-left: 10px;\n }\n }\n }\n mat-card-content {\n overflow: hidden;\n text-wrap: none;\n text-overflow: ellipsis;\n }\n mat-card-actions {\n display: flex;\n flex: 1 0 auto;\n align-items: flex-end;\n }\n mat-icon.mat-card-avatar {\n width: 40px;\n height: 40px;\n font-size: 40px;\n color: var(--accent-color);\n }\n .show-more-text {\n margin-top: -70px;\n background: rgb(255, 255, 255);\n background: linear-gradient(\n rgba(255, 255, 255, 0.1) 0%,\n rgba(255, 255, 255, 0.3) 10%,\n rgba(255, 255, 255, 0.5) 20%,\n rgba(255, 255, 255, 0.8) 30%,\n rgba(255, 255, 255, 1) 100%\n );\n text-align: center;\n padding: 10px 25px;\n backdrop-filter: blur(1px);\n }\n .show-more-open {\n margin-top: -10px;\n padding: 10px;\n }\n }\n}\n",
"styleUrl": "./result-entry.component.scss"
}
],
Expand Down Expand Up @@ -3798,7 +3798,7 @@
"AfterViewInit",
"OnChanges"
],
"templateData": "<mat-card\n class=\"result-entry\"\n (click)=\"\n entry.actions && entry.actions.length <= 0\n ? emitActionEvent('cardClick')\n : ''\n \"\n *ngIf=\"entry.title || entry.description\"\n>\n <mat-card-header>\n <img\n *ngIf=\"entry.avatarImgSrc\"\n mat-card-avatar\n matTooltip=\"{{ entry.avatarToolTip! | translate }}\"\n [src]=\"entry.avatarImgSrc\"\n [alt]=\"entry.title\"\n />\n <mat-icon\n *ngIf=\"entry.avatarIcon\"\n matTooltip=\"{{ entry.avatarToolTip! | translate }}\"\n mat-card-avatar\n >{{ entry.avatarIcon }}</mat-icon\n >\n <mat-card-title [innerHTML]=\"entry.title\"></mat-card-title>\n <mat-card-subtitle>\n <div class=\"subtitle-container\">\n <ng-container *ngFor=\"let subTitle of entry.subTitles\">\n <mat-icon>{{ subTitle.icon }}</mat-icon>\n {{ subTitle.description! | translate }}\n </ng-container>\n </div>\n </mat-card-subtitle>\n </mat-card-header>\n <img\n *ngIf=\"entry.imageSrc\"\n mat-card-image\n [src]=\"entry.imageSrc\"\n [alt]=\"entry.title\"\n />\n <mat-card-content>\n <mat-chip-list>\n <mat-chip *ngFor=\"let tag of entry.tags\">\n {{ tag | translate }}\n </mat-chip>\n </mat-chip-list>\n <p [innerHTML]=\"getEntryDescription()\"></p>\n </mat-card-content>\n <button\n *ngIf=\"checkIfNeedShowMore()\"\n (click)=\"showMoreContent = !showMoreContent\"\n [class.show-more-open]=\"showMoreContent\"\n mat-button\n class=\"show-more-text\"\n color=\"primary\"\n >\n {{ getShowMoreButtonDescription() | async }}\n </button>\n <mat-card-actions>\n <button\n *ngFor=\"let action of entry.actions\"\n mat-icon-button\n [matTooltip]=\"action.description ? (action.description | translate) : ''\"\n (click)=\"emitActionEvent(action.name)\"\n >\n <mat-icon>{{ action.icon }}</mat-icon>\n </button>\n </mat-card-actions>\n</mat-card>\n"
"templateData": "<mat-card\n class=\"result-entry\"\n (click)=\"\n !entry.actions\n ? emitActionEvent('cardClick')\n : ''\n \"\n *ngIf=\"entry.title || entry.description\"\n>\n <mat-card-header>\n <img\n *ngIf=\"entry.avatarImgSrc\"\n mat-card-avatar\n matTooltip=\"{{ entry.avatarToolTip! | translate }}\"\n [src]=\"entry.avatarImgSrc\"\n [alt]=\"entry.title\"\n />\n <mat-icon\n *ngIf=\"entry.avatarIcon\"\n matTooltip=\"{{ entry.avatarToolTip! | translate }}\"\n mat-card-avatar\n >{{ entry.avatarIcon }}</mat-icon\n >\n <mat-card-title [innerHTML]=\"entry.title\"></mat-card-title>\n <mat-card-subtitle>\n <div class=\"subtitle-container\">\n <ng-container *ngFor=\"let subTitle of entry.subTitles\">\n <mat-icon>{{ subTitle.icon }}</mat-icon>\n {{ subTitle.description! | translate }}\n </ng-container>\n </div>\n </mat-card-subtitle>\n </mat-card-header>\n <img\n *ngIf=\"entry.imageSrc\"\n mat-card-image\n [src]=\"entry.imageSrc\"\n [alt]=\"entry.title\"\n />\n <mat-card-content>\n <mat-chip-list>\n <mat-chip *ngFor=\"let tag of entry.tags\">\n {{ tag | translate }}\n </mat-chip>\n </mat-chip-list>\n <p [innerHTML]=\"getEntryDescription()\"></p>\n </mat-card-content>\n <button\n *ngIf=\"checkIfNeedShowMore()\"\n (click)=\"showMoreContent = !showMoreContent\"\n [class.show-more-open]=\"showMoreContent\"\n mat-button\n class=\"show-more-text\"\n color=\"primary\"\n >\n {{ getShowMoreButtonDescription() | async }}\n </button>\n <mat-card-actions>\n <button\n *ngFor=\"let action of entry.actions\"\n mat-icon-button\n [matTooltip]=\"action.description ? (action.description | translate) : ''\"\n (click)=\"emitActionEvent(action.name)\"\n >\n <mat-icon>{{ action.icon }}</mat-icon>\n </button>\n </mat-card-actions>\n</mat-card>\n"
},
{
"name": "ResultsComponent",
Expand Down Expand Up @@ -3889,7 +3889,7 @@
"args": [],
"line": 18
},
"templateData": "<div\n class=\"search-results\"\n [ngClass]=\"{\n 'search-results-grid': resultType === 'grid',\n 'search-results-list': resultType === 'list'\n }\"\n>\n <amsui-result-entry\n *ngFor=\"let entry of results\"\n [entry]=\"entry\"\n [highlightingActivated]=\"highlightingActivated\"\n (actionClicked)=\"emitActionEvent($event)\"\n ></amsui-result-entry>\n</div>\n"
"templateData": "<div\n class=\"search-results\"\n [ngClass]=\"{\n 'search-results-grid': resultType === 'grid',\n 'search-results-list': resultType === 'list'\n }\"\n>\n <ng-container\n *ngFor=\"let entry of results\">\n <amsui-result-entry\n *ngIf=\"entry.title || entry.description\"\n [entry]=\"entry\"\n [highlightingActivated]=\"highlightingActivated\"\n (actionClicked)=\"emitActionEvent($event)\"\n ></amsui-result-entry>\n\n </ng-container>\n</div>\n"
},
{
"name": "ResultTypeComponent",
Expand Down Expand Up @@ -6222,39 +6222,39 @@
"name": "Default",
"ctype": "miscellaneous",
"subtype": "variable",
"file": "projects/amsui/src/lib/search-field/search-field.stories.ts",
"file": "projects/amsui/src/lib/overlay-loader/overlay-loader.stories.ts",
"type": "",
"defaultValue": "Template.bind({})"
},
{
"name": "Default",
"ctype": "miscellaneous",
"subtype": "variable",
"file": "projects/amsui/src/lib/search-result-meta/search-results-meta.stories.ts",
"file": "projects/amsui/src/lib/search-field/search-field.stories.ts",
"type": "",
"defaultValue": "Template.bind({})"
},
{
"name": "Default",
"ctype": "miscellaneous",
"subtype": "variable",
"file": "projects/amsui/src/lib/overlay-loader/overlay-loader.stories.ts",
"file": "projects/amsui/src/lib/results/results.stories.ts",
"type": "",
"defaultValue": "Template.bind({})"
},
{
"name": "Default",
"ctype": "miscellaneous",
"subtype": "variable",
"file": "projects/amsui/src/lib/search-results-wrapper/search-results-wrapper.stories.ts",
"file": "projects/amsui/src/lib/search-result-meta/search-results-meta.stories.ts",
"type": "",
"defaultValue": "Template.bind({})"
},
{
"name": "Default",
"ctype": "miscellaneous",
"subtype": "variable",
"file": "projects/amsui/src/lib/results/results.stories.ts",
"file": "projects/amsui/src/lib/search-results-wrapper/search-results-wrapper.stories.ts",
"type": "",
"defaultValue": "Template.bind({})"
},
Expand All @@ -6270,31 +6270,31 @@
"name": "Default",
"ctype": "miscellaneous",
"subtype": "variable",
"file": "projects/amsui/src/lib/search-result-meta/result-type/result-type.stories.ts",
"file": "projects/amsui/src/lib/results/result-entry/result-entry.stories.ts",
"type": "",
"defaultValue": "Template.bind({})"
},
{
"name": "Default",
"ctype": "miscellaneous",
"subtype": "variable",
"file": "projects/amsui/src/lib/search-result-meta/search-result-text/search-result-text.stories.ts",
"file": "projects/amsui/src/lib/search-result-meta/result-type/result-type.stories.ts",
"type": "",
"defaultValue": "Template.bind({})"
},
{
"name": "Default",
"ctype": "miscellaneous",
"subtype": "variable",
"file": "projects/amsui/src/lib/search-result-meta/sorting-select/sorting-select.stories.ts",
"file": "projects/amsui/src/lib/search-result-meta/search-result-text/search-result-text.stories.ts",
"type": "",
"defaultValue": "Template.bind({})"
},
{
"name": "Default",
"ctype": "miscellaneous",
"subtype": "variable",
"file": "projects/amsui/src/lib/results/result-entry/result-entry.stories.ts",
"file": "projects/amsui/src/lib/search-result-meta/sorting-select/sorting-select.stories.ts",
"type": "",
"defaultValue": "Template.bind({})"
},
Expand Down Expand Up @@ -6624,6 +6624,14 @@
"type": "Story<NoResultsComponent>",
"defaultValue": "(\n args: NoResultsComponent\n) => ({\n component: NoResultsComponent,\n props: args,\n})"
},
{
"name": "Template",
"ctype": "miscellaneous",
"subtype": "variable",
"file": "projects/amsui/src/lib/overlay-loader/overlay-loader.stories.ts",
"type": "Story<OverlayLoaderComponent>",
"defaultValue": "(\n args: OverlayLoaderComponent\n) => ({\n component: OverlayLoaderComponent,\n props: args,\n})"
},
{
"name": "Template",
"ctype": "miscellaneous",
Expand All @@ -6636,17 +6644,17 @@
"name": "Template",
"ctype": "miscellaneous",
"subtype": "variable",
"file": "projects/amsui/src/lib/search-result-meta/search-results-meta.stories.ts",
"type": "Story<SearchResultMetaComponent>",
"defaultValue": "(\n args: SearchResultMetaComponent\n) => ({\n component: SearchResultMetaComponent,\n props: args,\n})"
"file": "projects/amsui/src/lib/results/results.stories.ts",
"type": "Story<ResultsComponent>",
"defaultValue": "(args: ResultsComponent) => ({\n component: ResultsComponent,\n props: args,\n})"
},
{
"name": "Template",
"ctype": "miscellaneous",
"subtype": "variable",
"file": "projects/amsui/src/lib/overlay-loader/overlay-loader.stories.ts",
"type": "Story<OverlayLoaderComponent>",
"defaultValue": "(\n args: OverlayLoaderComponent\n) => ({\n component: OverlayLoaderComponent,\n props: args,\n})"
"file": "projects/amsui/src/lib/search-result-meta/search-results-meta.stories.ts",
"type": "Story<SearchResultMetaComponent>",
"defaultValue": "(\n args: SearchResultMetaComponent\n) => ({\n component: SearchResultMetaComponent,\n props: args,\n})"
},
{
"name": "Template",
Expand All @@ -6660,17 +6668,17 @@
"name": "Template",
"ctype": "miscellaneous",
"subtype": "variable",
"file": "projects/amsui/src/lib/results/results.stories.ts",
"type": "Story<ResultsComponent>",
"defaultValue": "(args: ResultsComponent) => ({\n component: ResultsComponent,\n props: args,\n})"
"file": "projects/amsui/src/lib/facets/facet/facet.stories.ts",
"type": "Story<FacetComponent>",
"defaultValue": "(args: FacetComponent) => ({\n component: FacetComponent,\n props: args,\n})"
},
{
"name": "Template",
"ctype": "miscellaneous",
"subtype": "variable",
"file": "projects/amsui/src/lib/facets/facet/facet.stories.ts",
"type": "Story<FacetComponent>",
"defaultValue": "(args: FacetComponent) => ({\n component: FacetComponent,\n props: args,\n})"
"file": "projects/amsui/src/lib/results/result-entry/result-entry.stories.ts",
"type": "Story<ResultEntryComponent>",
"defaultValue": "(args: ResultEntryComponent) => ({\n component: ResultEntryComponent,\n props: args,\n})"
},
{
"name": "Template",
Expand Down Expand Up @@ -6704,14 +6712,6 @@
"type": "Story<SortingSelectComponent>",
"defaultValue": "(\n args: SortingSelectComponent\n) => ({\n component: SortingSelectComponent,\n props: args,\n})"
},
{
"name": "Template",
"ctype": "miscellaneous",
"subtype": "variable",
"file": "projects/amsui/src/lib/results/result-entry/result-entry.stories.ts",
"type": "Story<ResultEntryComponent>",
"defaultValue": "(args: ResultEntryComponent) => ({\n component: ResultEntryComponent,\n props: args,\n})"
},
{
"name": "WithActions",
"ctype": "miscellaneous",
Expand Down
4 changes: 2 additions & 2 deletions projects/amsui/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion projects/amsui/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@redlink/amsui",
"version": "0.0.3",
"version": "0.0.4",
"description": "Search UI elements on top of Angular Material",
"author": "redlink",
"license": "MIT",
Expand Down
2 changes: 1 addition & 1 deletion projects/amsui/src/docs/backend-integration.stories.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ When using the included Solr Service, the new values will be set on each new req
Just inject the search service to your components constructor

```
import { SearchService } from 'amsui';
import { SearchService } from '@redlink/amsui';
constructor(private readonly searchService: SearchService) { ... }
```

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<mat-card
class="result-entry"
(click)="
entry.actions && entry.actions.length <= 0
!entry.actions
? emitActionEvent('cardClick')
: ''
"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,11 @@
display: flex;
align-items: center;
flex-wrap: wrap;
mat-icon:not(:first-child) {
margin-left: 5px;
mat-icon {
margin-right: 5px;
&:not(:first-child) {
margin-left: 10px;
}
}
}
mat-card-content {
Expand Down
16 changes: 10 additions & 6 deletions projects/amsui/src/lib/results/results.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,14 @@
'search-results-list': resultType === 'list'
}"
>
<amsui-result-entry
*ngFor="let entry of results"
[entry]="entry"
[highlightingActivated]="highlightingActivated"
(actionClicked)="emitActionEvent($event)"
></amsui-result-entry>
<ng-container
*ngFor="let entry of results">
<amsui-result-entry
*ngIf="entry.title || entry.description"
[entry]="entry"
[highlightingActivated]="highlightingActivated"
(actionClicked)="emitActionEvent($event)"
></amsui-result-entry>

</ng-container>
</div>

0 comments on commit 178c6b7

Please sign in to comment.