Quellcode durchsuchen

Update 'src/app/component-registry/line-component.js'

Added header
Changes to use object constructor "description" (app/core/models/components/component-options.js) in button (app/core/application/menu.js)
New field to new ComponentOptions(...): "Construct a Line between two points (select those 2 points)",
leo vor 1 Jahr
Ursprung
Commit
da77951afb
1 geänderte Dateien mit 24 neuen und 4 gelöschten Zeilen
  1. 24 4
      src/app/component-registry/line-component.js

+ 24 - 4
src/app/component-registry/line-component.js

@@ -1,15 +1,35 @@
+/*
+ * iGeom by LInE
+ * Free software to student private data
+ *
+ * http://www.matematica.br/igeom
+ * http://www.usp.br/line
+ *
+ * Create and register new element MidPoint
+ * It is used in ./app/core/application/menu.js
+ *
+ * ./app/component-registry/line-component.js
+ * @version 2023/09/20: Added new parameter 'description,' to 'ComponentOptions'
+ */
+
 import { Component } from "../core/models/components/component";
 import { ComponentOptions } from "../core/models/components/component-options";
 import { LineDrawer } from "../components/line-component/drawers/line-drawer";
+
 class LineComponent extends Component {
-  constructor() {
+
+  //TODO: it is necessary internationalization!
+
+  constructor () {
     const options = new ComponentOptions(
       "aa5962d0-8f90-45b3-91db-61e0de6809ae",
       "Line",
+      "Construct a Line between two points (select those 2 points)",
       "line"
-    );
+      );
     super(new LineDrawer(), options);
+    }
+
   }
-}
 
-export const lineComponent = new LineComponent();
+export const lineComponent = new LineComponent();