瀏覽代碼

doc more methods and why the id must be unique

Paul Ivanov 8 年之前
父節點
當前提交
8352314a8d
共有 1 個文件被更改,包括 10 次插入1 次删除
  1. 10 1
      src/application/shell.ts

+ 10 - 1
src/application/shell.ts

@@ -162,7 +162,7 @@ class ApplicationShell extends Widget {
    * Add a widget to the top content area.
    * Add a widget to the top content area.
    *
    *
    * #### Notes
    * #### Notes
-   * Widgets must have a unique `id` property
+   * Widgets must have a unique `id` property, which will be used as the DOM id.
    */
    */
   addToTopArea(widget: Widget, options: ISideAreaOptions = {}): void {
   addToTopArea(widget: Widget, options: ISideAreaOptions = {}): void {
     if (!widget.id) {
     if (!widget.id) {
@@ -175,6 +175,9 @@ class ApplicationShell extends Widget {
 
 
   /**
   /**
    * Add a widget to the left content area.
    * Add a widget to the left content area.
+   *
+   * #### Notes
+   * Widgets must have a unique `id` property, which will be used as the DOM id.
    */
    */
   addToLeftArea(widget: Widget, options: ISideAreaOptions = {}): void {
   addToLeftArea(widget: Widget, options: ISideAreaOptions = {}): void {
     if (!widget.id) {
     if (!widget.id) {
@@ -187,6 +190,9 @@ class ApplicationShell extends Widget {
 
 
   /**
   /**
    * Add a widget to the right content area.
    * Add a widget to the right content area.
+   *
+   * #### Notes
+   * Widgets must have a unique `id` property, which will be used as the DOM id.
    */
    */
   addToRightArea(widget: Widget, options: ISideAreaOptions = {}): void {
   addToRightArea(widget: Widget, options: ISideAreaOptions = {}): void {
     if (!widget.id) {
     if (!widget.id) {
@@ -199,6 +205,9 @@ class ApplicationShell extends Widget {
 
 
   /**
   /**
    * Add a widget to the main content area.
    * Add a widget to the main content area.
+   *
+   * #### Notes
+   * Widgets must have a unique `id` property, which will be used as the DOM id.
    */
    */
   addToMainArea(widget: Widget): void {
   addToMainArea(widget: Widget): void {
     // TODO
     // TODO