-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #85 from ride90/v0.5
V0.5
- Loading branch information
Showing
38 changed files
with
3,609 additions
and
890 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
interface Subject { | ||
id: string; | ||
name: string; | ||
} | ||
|
||
export default class BelgaSearchPanelController { | ||
languages: Array<Subject>; | ||
periods: Array<Subject>; | ||
types: Array<Subject>; | ||
|
||
$onInit() { | ||
this.languages = [ | ||
{ name: "DE", id: "de" }, | ||
{ name: "FR", id: "fr" }, | ||
{ name: "EN", id: "en" }, | ||
{ name: "ES", id: "es" }, | ||
{ name: "NL", id: "nl" } | ||
]; | ||
|
||
this.types = [ | ||
{ name: "alert", id: "alert" }, | ||
{ name: "text", id: "text" }, | ||
{ name: "brief", id: "brief" }, | ||
{ name: "short", id: "short" } | ||
]; | ||
|
||
this.periods = [ | ||
{ name: "Whenever", id: "" }, | ||
{ name: "Last 4 hours", id: "last4h" }, | ||
{ name: "Last 8 hours", id: "last8h" }, | ||
{ name: "Today", id: "today" }, | ||
{ name: "Yesterday", id: "yesterday" }, | ||
{ name: "Last 24 hours", id: "day" }, | ||
{ name: "Last 48 hours", id: "last48h" }, | ||
{ name: "Last 72 hours", id: "last74h" }, | ||
{ name: "Last week", id: "week1" }, | ||
{ name: "Last 2 weeks", id: "week2" }, | ||
{ name: "Last month", id: "month" }, | ||
{ name: "Last year", id: "year" }, | ||
{ name: "Last 2 years", id: "year2" } | ||
]; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
import angular from 'angular'; | ||
|
||
import BelgaSearchPanelController from './BelgaSearchPanelController'; | ||
|
||
export default angular.module('belga.360archive', [ | ||
]) | ||
.controller('BelgaSearchPanelController', BelgaSearchPanelController) | ||
.run(['$templateCache',($templateCache) => { | ||
$templateCache.put( | ||
'search-panel-belga_360archive.html', | ||
require('./views/search-panel.html') | ||
); | ||
}]) | ||
; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
<fieldset ng-controller="BelgaSearchPanelController as searchPanel"> | ||
<div class="field"> | ||
<label for="search-headline">{{:: 'Headline' | translate}}</label> | ||
<div class="control"> | ||
<input type="text" id="search-headline" ng-model="params.headline" tabindex="1"> | ||
</div> | ||
</div> | ||
|
||
<div class="field"> | ||
<label class="search-label">Language</label> | ||
<select ng-model="params.languages"> | ||
<option ng-repeat="language in searchPanel.languages" value="{{ language.id }}">{{ language.name }}</option> | ||
</select> | ||
</div> | ||
|
||
<div class="field"> | ||
<label class="search-label">Content type</label> | ||
<select ng-model="params.types"> | ||
<option ng-repeat="type in searchPanel.types" value="{{ type.id }}">{{ type.name }}</option> | ||
</select> | ||
</div> | ||
|
||
<div class="field"> | ||
<label for="search-headline">{{:: 'Credits' | translate}}</label> | ||
<div class="control"> | ||
<input type="text" id="search-credits" ng-model="params.credits" tabindex="1"> | ||
</div> | ||
</div> | ||
|
||
<div class="field"> | ||
<label class="search-label" translate>Period</label> | ||
<select ng-model="params.period"> | ||
<option ng-repeat="period in searchPanel.periods" value="{{ period.id }}">{{ period.name }}</option> | ||
</select> | ||
</div> | ||
<div class="form__row form__row--flex form__row--small-padding"> | ||
<div class="form__row-item"> | ||
<label class="form-label" translate>From</label> | ||
<div sd-datepicker | ||
ng-model="params.dates.start" | ||
data-on-change="onDatesChange()" | ||
></div> | ||
</div> | ||
<div class="form__row-item"> | ||
<label class="form-label" translate>To</label> | ||
<div sd-datepicker | ||
ng-model="params.dates.end" | ||
data-on-change="onDatesChange()" | ||
></div> | ||
</div> | ||
</div> | ||
</fieldset> |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
import React from 'react'; | ||
import angular from 'angular'; | ||
import {IUser} from 'superdesk-api' | ||
import {startApp} from 'superdesk-core/scripts/index'; | ||
import belgaImage from './image'; | ||
import belga360Archive from './360archive'; | ||
|
||
class UserAvatar extends React.Component<{user: IUser}> { | ||
render() { | ||
return ( | ||
<div className="user-avatar" data-test-id="user-avatar"> | ||
<figure className="avatar avatar--no-margin initials"> | ||
{this.props.user.sign_off} | ||
</figure> | ||
</div> | ||
); | ||
} | ||
} | ||
|
||
setTimeout(() => { | ||
startApp({UserAvatar}); | ||
}); | ||
|
||
export default angular.module('belga', [ | ||
belgaImage.name, | ||
belga360Archive.name, | ||
]); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
/// <reference path='../../../client/node_modules/superdesk-core/scripts/core/superdesk-api.d.ts' /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.