diff --git a/web/static/src/scss/app.scss b/web/static/src/scss/app.scss
index e1b08497..debf10f6 100644
--- a/web/static/src/scss/app.scss
+++ b/web/static/src/scss/app.scss
@@ -1,7 +1,50 @@
+// ------------------------------------------------------------------
+// Variables
+// ------------------------------------------------------------------
$navbar-height: 46px;
$main-color: #875a7b;
$o-main-text-color: #666666;
+$o-notification-info-bg-color: #fcfbea;
+$o-notification-error-bg-color: #f16567;
+$o-view-background-color: white;
+$o-control-panel-background-color: $o-view-background-color;
+$o-horizontal-padding: 16px;
+$o-cp-breadcrumb-height: 30px;
+// bootstrap overrides
+// this does not work: $breadcrumb-bg: $o-control-panel-background-color;
+.breadcrumb {
+ background-color: white;
+ padding: 0;
+}
+
+// ------------------------------------------------------------------
+// Mixins
+// ------------------------------------------------------------------
+@mixin o-webclient-padding(
+ $top: 0px,
+ $right: $o-horizontal-padding,
+ $bottom: 0px,
+ $left: $o-horizontal-padding
+) {
+ padding-top: $top;
+ padding-right: $right;
+ padding-bottom: $bottom;
+ padding-left: $left;
+}
+
+@mixin o-text-overflow($display: inline-block, $max-width: 100%) {
+ display: $display;
+ max-width: $max-width;
+ white-space: nowrap;
+ overflow: hidden;
+ text-overflow: ellipsis;
+ vertical-align: top; // To update display context changed by overflow:hidden
+}
+
+// ------------------------------------------------------------------
+// CSS
+// ------------------------------------------------------------------
html {
height: 100%;
}
@@ -138,9 +181,6 @@ body {
}
/***** Notifications *****/
-$o-notification-info-bg-color: #fcfbea;
-$o-notification-error-bg-color: #f16567;
-
.o_notification_container {
position: absolute;
width: 300px;
@@ -190,9 +230,20 @@ $o-notification-error-bg-color: #f16567;
}
/***** Discuss *****/
-.o_discuss {
- padding: 20px;
+.o_discuss .o_content {
font-size: 15px;
+ display: flex;
+
+ .o_discuss_sidebar {
+ background-color: #212529;
+ flex: 0 0 300px;
+ color: white;
+ padding: 20px;
+ }
+ .o_discuss_content {
+ padding: 20px;
+ flex: 1 1 auto;
+ }
button {
padding: 5px;
@@ -210,3 +261,81 @@ $o-notification-error-bg-color: #f16567;
padding: 4px;
font-size: 14px;
}
+
+/***** Control Panel *****/
+.o_control_panel {
+ display: flex;
+ flex-flow: row wrap;
+ border-bottom: 1px solid darken($o-control-panel-background-color, 20%);
+ @include o-webclient-padding($top: 10px, $bottom: 10px);
+ background-color: $o-control-panel-background-color;
+
+ > .breadcrumb {
+ width: 50%;
+ font-size: 18px;
+
+ > li {
+ @include o-text-overflow($max-width: 90%);
+
+ > a {
+ cursor: pointer;
+ }
+ }
+ }
+
+ > .o_cp_searchview {
+ width: 50%;
+ min-height: $o-cp-breadcrumb-height;
+ }
+
+ > .o_cp_left {
+ display: flex;
+ justify-content: space-between;
+ width: 50%;
+ margin-top: 5px;
+
+ > .o_cp_sidebar {
+ padding-right: 10px;
+ }
+ }
+
+ > .o_cp_right {
+ display: flex;
+ width: 50%;
+ margin-top: 5px;
+
+ > .o_cp_pager {
+ margin: auto 0 auto auto;
+ padding-left: 5px;
+ text-align: center;
+ user-select: none;
+
+ > div {
+ display: flex;
+ align-items: center;
+ }
+
+ .o_pager_counter {
+ margin-right: 5px;
+ }
+ }
+ }
+}
+
+/***** Action Controller *****/
+.o_action_controller {
+ height: 100%;
+ display: flex;
+ flex-flow: column nowrap;
+ padding: 0;
+
+ > .o_cp_controller {
+ flex: 0 0 auto;
+ }
+
+ > .o_content {
+ overflow: auto;
+ flex: 1 1 100%;
+ position: relative;
+ }
+}
diff --git a/web/static/src/ts/discuss/discuss.ts b/web/static/src/ts/discuss/discuss.ts
index 56840789..f4db91f9 100644
--- a/web/static/src/ts/discuss/discuss.ts
+++ b/web/static/src/ts/discuss/discuss.ts
@@ -1,7 +1,7 @@
import { Clock } from "./clock";
import { Counter } from "./counter";
import { Widget } from "../widget";
-
+import { ControlPanel } from "../ui/control_panel";
//------------------------------------------------------------------------------
// Types
//------------------------------------------------------------------------------
@@ -17,7 +17,7 @@ interface State {
export class Discuss extends Widget<{}, State> {
template = "web.discuss";
- widgets = { Clock, Counter, ColorWidget };
+ widgets = { Clock, Counter, ColorWidget, ControlPanel };
state: State = { validcounter: true, color: "red" };
resetCounter(ev: MouseEvent) {
diff --git a/web/static/src/ts/env.ts b/web/static/src/ts/env.ts
index 1d49c180..9988a238 100644
--- a/web/static/src/ts/env.ts
+++ b/web/static/src/ts/env.ts
@@ -2,7 +2,8 @@ import { WEnv } from "./core/component";
import { QWeb } from "./core/qweb_vdom";
import { Registry } from "./core/registry";
import { idGenerator } from "./core/utils";
-import { RPC } from "./services/ajax";
+import { RPC as RPCService } from "./services/ajax";
+import { RPC } from "./store/store";
import { IRouter } from "./services/router";
import { ControllerWidget, Store, Notification } from "./store/store";
@@ -11,7 +12,7 @@ import { ControllerWidget, Store, Notification } from "./store/store";
//------------------------------------------------------------------------------
export interface Services {
- rpc: RPC;
+ rpc: RPCService;
router: IRouter;
}
diff --git a/web/static/src/ts/store/action_manager_mixin.ts b/web/static/src/ts/store/action_manager_mixin.ts
index 018cdcf6..19bf840a 100644
--- a/web/static/src/ts/store/action_manager_mixin.ts
+++ b/web/static/src/ts/store/action_manager_mixin.ts
@@ -95,7 +95,10 @@ export function actionManagerMixin