Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
D
DV-HW4
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
almohanad.hafez
DV-HW4
Commits
0a8a1501
You need to sign in or sign up before continuing.
Commit
0a8a1501
authored
Jan 10, 2025
by
Almouhannad Hafez
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update Chart
parent
769bf50f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
chart.ts
src/ts/chart.ts
+3
-3
No files found.
src/ts/chart.ts
View file @
0a8a1501
...
...
@@ -8,7 +8,7 @@ export abstract class Chart {
containerHeight
:
number
;
margin
:
{
top
:
number
;
right
:
number
;
bottom
:
number
;
left
:
number
;
};
};
p
rotected
data
:
any
[];
p
ublic
data
:
any
[];
protected
width
:
number
;
protected
height
:
number
;
protected
svg
:
d3
.
Selection
<
d3
.
BaseType
,
unknown
,
HTMLElement
,
any
>
;
...
...
@@ -19,7 +19,7 @@ export abstract class Chart {
/**
* Class constructor with basic chart configuration
*/
constructor
(
_config
:
ChartConfiguration
,
_data
:
any
[])
{
constructor
(
_config
:
ChartConfiguration
,
_data
?
:
any
[])
{
const
vis
=
this
;
...
...
@@ -31,7 +31,7 @@ export abstract class Chart {
containerHeight
:
height
,
margin
:
_config
.
margin
||
vis
.
getDefaultMargins
()
};
vis
.
data
=
_data
;
vis
.
data
=
_data
||
[]
;
vis
.
initChart
();
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment