Skip to content

mutator-tech-cto/metasphere-react-prototype

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MetaSphere React Prototype

Codacy Badge

Rationale

I want to map a tree of textified elements into the flow of sectors split by concetric circles and radial segments.

models ? schema

{
    metasphere: {
        possibleKeys: [{
          name: "sectors",
          kind: "sectorArray"
        }]
    },
    sectorObject: {
        possibleKeys: [{
            name: "id",
            kind: "$id$"
        }, {
            name: "content",
            kind: "String"
        }, {
            name: "children",
            kind: "sectorArray"
        }]
    },
    sectorArray: {
        possibleKeys: [{
            name: "$identifier$",
            kind: "sectorObject"
        }]
    }
}

model[metasphere] ~> map[some math] ~> view[metasphere]

  1. Prepare metasphere model.
const pseudoSectors = metasphere.sectors.map(
    sector => {
        identifier: metasphere.nextIdentifier(sector.identifier),
        parentRingOrderNumber: deep(sector),
        parentRingSectorOrderNumber: length(previous(sector))
    }
);
  1. Do some math.
const mathematizedSectors = pseudoSectors.map(
    pseudoSector => {
        ring: ...
    }
)
  1. Render mathematized pseudo sectors.
Where react comes.

About

prototype(widget) { metasphere in react }

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published