Full node appearance

image

Hi,

Is there any way to edit more deeply the nodes instead of background color. For example, I would like to change ports position even port style, like the image above...

Is this possible with Node-RED?

All things are possible - it's "just" software and the source is freely available. But no we don't support that within the core project per se - so you would need to fork it and do the rework yourself.

Okey. I'm gonna try. Let me ask another question about this, I realised that the UI uses the editor/templates/index.mst file so changing it I can edit the UI. Which is the file for edit nodes globally?

Well that is the main page template - most of the layout heavy lifting is done in ./packages/node_modules/@node-red/editor-client/src/js/ui/view.js

That's the path to the file in the dev branch on git which will be the 0.20 release.

If you're looking at the master branch, you'd want:

editor/js/ui/view.js

In the npm installed version of Node-RED, all of the editor source has already been combined and minified into red.min.js - you cant easily edit that directly.

2 Likes

Sorry if my question is a little dummy. But I can't find the file that you have mentioned. When I installed Node-RED I got this files:

/usr/local/lib/node_modules/node-red
    โ”œโ”€โ”€ bin
    โ”œโ”€โ”€ editor
    โ”‚   โ””โ”€โ”€ templates
    โ”œโ”€โ”€ node_modules [282 entries exceeds filelimit, not opening dir]
    โ”œโ”€โ”€ nodes
    โ”‚   โ””โ”€โ”€ core
    โ”‚       โ”œโ”€โ”€ analysis
    โ”‚       โ”œโ”€โ”€ core
    โ”‚       โ”‚   โ””โ”€โ”€ lib
    โ”‚       โ”‚       โ””โ”€โ”€ debug
    โ”‚       โ”œโ”€โ”€ hardware
    โ”‚       โ”œโ”€โ”€ io
    โ”‚       โ”‚   โ””โ”€โ”€ lib
    โ”‚       โ”œโ”€โ”€ locales
    โ”‚       โ”‚   โ”œโ”€โ”€ en-US
    โ”‚       โ”‚   โ”œโ”€โ”€ ja
    โ”‚       โ”‚   โ”‚   โ”œโ”€โ”€ analysis
    โ”‚       โ”‚   โ”‚   โ”œโ”€โ”€ core
    โ”‚       โ”‚   โ”‚   โ”œโ”€โ”€ hardware
    โ”‚       โ”‚   โ”‚   โ”œโ”€โ”€ io
    โ”‚       โ”‚   โ”‚   โ”œโ”€โ”€ logic
    โ”‚       โ”‚   โ”‚   โ”œโ”€โ”€ parsers
    โ”‚       โ”‚   โ”‚   โ””โ”€โ”€ storage
    โ”‚       โ”‚   โ””โ”€โ”€ zh-CN
    โ”‚       โ”œโ”€โ”€ logic
    โ”‚       โ”œโ”€โ”€ parsers
    โ”‚       โ””โ”€โ”€ storage
    โ”œโ”€โ”€ public
    โ”‚   โ”œโ”€โ”€ icons
    โ”‚   โ”œโ”€โ”€ red
    โ”‚   โ”‚   โ””โ”€โ”€ images
    โ”‚   โ”‚       โ””โ”€โ”€ typedInput
    โ”‚   โ””โ”€โ”€ vendor
    โ”‚       โ”œโ”€โ”€ ace
    โ”‚       โ”‚   โ””โ”€โ”€ snippets
    โ”‚       โ”œโ”€โ”€ bootstrap
    โ”‚       โ”‚   โ”œโ”€โ”€ css
    โ”‚       โ”‚   โ””โ”€โ”€ img
    โ”‚       โ”œโ”€โ”€ font-awesome
    โ”‚       โ”‚   โ”œโ”€โ”€ css
    โ”‚       โ”‚   โ””โ”€โ”€ fonts
    โ”‚       โ”œโ”€โ”€ jquery
    โ”‚       โ”‚   โ””โ”€โ”€ css
    โ”‚       โ”‚       โ””โ”€โ”€ smoothness
    โ”‚       โ”‚           โ””โ”€โ”€ images
    โ”‚       โ””โ”€โ”€ jsonata
    โ””โ”€โ”€ red
        โ”œโ”€โ”€ api
        โ”‚   โ”œโ”€โ”€ admin
        โ”‚   โ”œโ”€โ”€ auth
        โ”‚   โ””โ”€โ”€ editor
        โ”‚       โ”œโ”€โ”€ locales
        โ”‚       โ”‚   โ”œโ”€โ”€ en-US
        โ”‚       โ”‚   โ”œโ”€โ”€ ja
        โ”‚       โ”‚   โ””โ”€โ”€ zh-CN
        โ”‚       โ””โ”€โ”€ projects
        โ””โ”€โ”€ runtime
            โ”œโ”€โ”€ locales
            โ”‚   โ”œโ”€โ”€ en-US
            โ”‚   โ””โ”€โ”€ ja
            โ”œโ”€โ”€ nodes
            โ”‚   โ”œโ”€โ”€ context
            โ”‚   โ”œโ”€โ”€ flows
            โ”‚   โ””โ”€โ”€ registry
            โ””โ”€โ”€ storage
                โ””โ”€โ”€ localfilesystem
                    โ””โ”€โ”€ projects
                        โ”œโ”€โ”€ git
                        โ””โ”€โ”€ ssh

Please read my reply. The npm installed version of Node-RED doesn't include the unbuilt source of the editor. If you want to edit the code, you'll need to clone from git and use the build process to generate the editor code.

1 Like

Hello, I have a similar requirement and need to align the input/output ports to the top and bottom of each custom node. If you are able to share how you accomplished this, I would greatly appreciate it.

There is this thread that demonstrates vertical flow and has a link to his source code. You should be able to view a diff and try it out on current node red source.

1 Like

Thanks @Steve-Mcl , I've become well acquainted with that thread :slight_smile: