All Projects → commutatus → cm-page-builder

commutatus / cm-page-builder

Licence: other
Page builder package like notion

Programming Languages

javascript
184084 projects - #8 most used programming language
SCSS
7915 projects
HTML
75241 projects

Projects that are alternatives of or similar to cm-page-builder

Codeblock Beautifier
A chrome extension for highlighting codes of Medium Articles
Stars: ✭ 109 (+275.86%)
Mutual labels:  medium
Docker tutorial
Code and helper scripts for article on Medium "How Docker Can Help You Become A More Effective Data Scientist"
Stars: ✭ 145 (+400%)
Mutual labels:  medium
Transport Eta
Twitch streamed 🎥playground repo, README speaks to you.
Stars: ✭ 223 (+668.97%)
Mutual labels:  medium
Bypass Paywalls Chrome Clean
Bypass Paywalls Clean for Chrome (no Google Analytics, lot of updates/bug-fixes and custom sites)
Stars: ✭ 125 (+331.03%)
Mutual labels:  medium
Micro Medium Api
Microservice for fetching the latest posts of Medium with GraphQL.
Stars: ✭ 138 (+375.86%)
Mutual labels:  medium
Medium Style Confirm
medium.com style confirm dialog
Stars: ✭ 164 (+465.52%)
Mutual labels:  medium
Blurimageview
BlurImageView, you can load your image progressively like Medium does.First show user a blurry image, At the same time, load the real image, once loaded, replace the blurry one automatically
Stars: ✭ 1,334 (+4500%)
Mutual labels:  medium
Medium Zoom
🔎🖼 A JavaScript library for zooming images like Medium
Stars: ✭ 2,799 (+9551.72%)
Mutual labels:  medium
My Medium Articles
List of my blog posts in the Medium
Stars: ✭ 143 (+393.1%)
Mutual labels:  medium
Epidemiology101
Epidemic Modeling for Everyone
Stars: ✭ 215 (+641.38%)
Mutual labels:  medium
Interesting People On Medium
Python script that finds interesting users from your Medium network to interact with
Stars: ✭ 126 (+334.48%)
Mutual labels:  medium
Bypass Paywalls Chrome Clean
Bypass Paywalls Clean for Chrome (no Google Analytics, lot of updates and bug-fixes)
Stars: ✭ 132 (+355.17%)
Mutual labels:  medium
Medium
Independent telecommunication environment
Stars: ✭ 171 (+489.66%)
Mutual labels:  medium
Darker Medium
Read Medium stories with happy eyes!
Stars: ✭ 123 (+324.14%)
Mutual labels:  medium
React Progressive Loader
Utility to load images and React components progressively, and get code splitting for free
Stars: ✭ 224 (+672.41%)
Mutual labels:  medium
Medium
📰 Developer versions of my Medium.com articles
Stars: ✭ 100 (+244.83%)
Mutual labels:  medium
Pymedium
Unofficial Medium Python Flask API and SDK
Stars: ✭ 153 (+427.59%)
Mutual labels:  medium
wysiwyg-editor-python-sdk
Python SDK to ease the integration of Froala WYSIWYG Editor on server side.
Stars: ✭ 20 (-31.03%)
Mutual labels:  rich-text-editor
Dat Medium
P2P Markdown Blog for Beaker inspired by Medium.
Stars: ✭ 225 (+675.86%)
Mutual labels:  medium
Sharect
🔗 A lightweight JavaScript library to let users share their text selections to social networks.
Stars: ✭ 192 (+562.07%)
Mutual labels:  medium

CM Page Builder

A Notion inspired page builder

CM Page builder is a modern rich text component based page builder inspired from Notion. This Component allows you to compose awesome, formatted text in your web application and supports uploading files, pictures, code snippets and even embedding videos.

Demo:

CM Page Builder 📝

Download and Install CM Page Builder

Install from npm

npm install -s cm-page-builder

Adding custom icon fonts

Add your font's link tag in index.html.
For example: <link rel="stylesheet" href="https://d1azc1qln24ryf.cloudfront.net/120939/EXPAV3/style-cf.css?crxvf0">

Load CM Page Builder as a Module

import PageBuilder from 'cm-page-builder'

Initialization and Usage

An Example of using page builder component:

<PageBuilder
	pageComponents={pageComponents}
	typeMapping={TYPE_MAP_COMPONENT}
	handleUpdate={this._updatePageComponent}
	status={this.state.status}
	requestHandler={this.requestHandler}
	options={[['Header1','Header2','Olist','Ulist']}
/>
Component Props
pageComponents
typeMapping
options
handleUpdate
status

Page components.

A list of Page components, to be initialized. They have the following structure

{
  component_attachment: { content: String, filename: String, url: String}
  component_type: String
  content: String
  position: Number
}

Status (default: Edit):

Has to be one of Edit or Read


options (default: ['Header1','Header2','Olist','Ulist','Embed','Upload', 'File','Divider','Code']):

Array of available components. For example, setting options as ['Header1'] will only render Header1 component.


handleUpdate(id, data, type, key):

A function that gets fired every time something happens with the components of a page. It receives four parameters, id, data, type, key

  • id: The ID of the component,
  • data: The data inside the component.
  • type: The kind of change that has happened with the component. It can be any of
    • "createComponent"
    • "updateComponent"
    • "deleteComponent"
  • key: undefined

typeMapping

A hash that maps snake_cased names of components with cm-page-builder components found inside the src/components folder. Available components are

  • Header1: The equivalent of a h1 tag
  • Header2: The equivalent of a h2 tag
  • OList: An ordered list. Two or more adjacent components of this type will make a group, and the position number will increase sequentially within that group
  • UList: An unordered list
  • Text: The default component, regular text. It may have HTML formatting
  • Embed: A vimeo or youtube video which is meant to be displayed as an embed file
  • Upload: A file. component_attachment will hold all relevant information. If it is an image, it should be displayed as an embedded image
  • Divider: A line divider.
  • Code: A code snippet component.

Crafted with ❤️ by Commutatus

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].