Giter VIP home page Giter VIP logo

umco / umbraco-inner-content Goto Github PK

View Code? Open in Web Editor NEW
2.0 2.0 16.0 4.29 MB

A helper library for Umbraco Doc Type based property editors providing overlays and conversion helpers

Home Page: https://our.umbraco.org/projects/backoffice-extensions/inner-content/

License: MIT License

C# 57.22% CSS 0.98% JavaScript 32.15% HTML 7.47% Batchfile 1.34% PowerShell 0.85%
property-editor umbraco umco

umbraco-inner-content's People

Contributors

leekelleher avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar  avatar

umbraco-inner-content's Issues

Idea: Content Templates (aka Blueprints)

Could Inner Content leverage the use of Content Templates (aka Blueprints) for content selection?

The use-case would be to pre-configure a content block, then let it be selectable from the Content Type picker overlay. We could attempt to re-use Umbraco's UI here?

This is open to community feedback.

Feature: Doc Type groups

When working with a large number of components it would helpful to be able to categorize them into groups and also search/filter them in the create overlay. I wouldn't mind working on a PR if this is something you'd consider.

Expand on PropertyValueEditorWrapper to handle basic JSON

Right now the base InnerContentPropertyValueEditorWrapper still expects the developer to unwrap the JSON and parse everything that isn't an Inner Content object. We could probably simplify this a little by letting it handle ANY JSON and detecting when it hits an Inner Content object to run the conversion.

This should be fine for most people who don't need to do any extra processing on their JSON model. For those that need to, they will implement as it's currently setup. Either way, this will add flexibility.

Support for Umbraco v8

This a placeholder issue to outline our intentions for Inner Content support on Umbraco v8.

Thoughts on supporting v8...

  • I posted some of my initial thoughts on Twitter.
  • We are curious of how v8's Infinite Editing feature could be leveraged.
  • We are curious of how NuCache could support the use of "real nodes".
  • We are curious of how content tabs would be displayed?
  • Are there any extra considerations for how variant's split-view would work?

From a historical perspective...

  • It is important to recall the history of this package library, keeping in mind that Inner Content (or more specifically Stacked Content) evolved from iterations of several packages, e.g. WidgetGrid, Mortar, Doc Type Grid Editor and Nested Content.
  • Inner Content was not invented before Umbraco v7.0 had been released.
  • Let's not rush to force support for Umbraco v8.0.

Prefix ContentTypeAliasPropertyKey with an underscore?

I'm wondering whether we should prefix the InnerContent specific properties with an underscore?

This would avoid any potential clashes with Umbraco property-alias names.

e.g. ContentTypeAliasPropertyKey = "_contentTypeAlias"

๐Ÿ˜ maybe a double underscore might look better?

Would there be any technical reasons to not do this? e.g. would Angular work okay with this?


@mattbrailsford - No biggie if you don't like the idea ๐Ÿ˜ƒ

Copied content and paste button stick around too long

When a stacked content item is copied it gets added to Local Storage, but is never removed. Since local storage does not expire this leads to a confusing UX. An editor may come back to editing a page days or weeks after copying a stacked content and still see the paste button, which leads to confusion.

I would propose either:

  1. Clear the copied item after it is pasted for the first time. If the user wanted more than one copy they would need to recopy.

  2. Only keep the copied item around for the current Umbraco session.

  3. A clear copied button. Could be more confusing since it doesn't mimic any other copy/paste experience.

Any thoughts? I'd be happy to do a PR.

Need a logo

Currently configured to use NC logo so we could do with it's own unique logo

Discard unsaved changes doesn't work when model.value is an object

I can't be sure if this is an Inner Content issue not (not sure how to test).

I have a simple property editor with two fields. For example, model.value.text and model.value.element. I make edits in the overlay and discard/cancel the changes and save. When I come back to the node, I see the "discarded" changes were saved.

Any ideas?

Write docs to raise awareness of the "System Property Keys"

Using a property alias such as "icon" can burn users, see Our Umbraco forum post for an example.

As of v1.1.1 (time of writing), we have the following...

private static bool IsSystemPropertyKey(string propKey)
{
    return propKey == "name"
        || propKey == "children"
        || propKey == "key"
        || propKey == "icon"
        || propKey == InnerContentConstants.ContentTypeGuidPropertyKey
        || propKey == InnerContentConstants.ContentTypeAliasPropertyKey;
}

ref: https://github.com/umco/umbraco-inner-content/blob/1.1.1/src/Our.Umbraco.InnerContent/PropertyEditors/InnerContentPropertyValueEditorWrapper.cs#L235-L243

More robust insert content overlay

The insert content overlay is cumbersome and difficult to navigate for editors when there are a large number of components. Something more robust than the item picker is needed. It could be that the entire UX of the insert content overlay needs to be rethought (as the issue exist within , but at the very least search filtering and component grouping would be helpful.

Update Courier/Deploy resolvers

Internal note:

Once v1.1.0 is out, we'll need to update the Courier resolver and Deploy connector...

We'll need to add in check to see if the icContentTypeGuid or icContentTypeAlias is available and perform the deployment logic accordingly.

Validation on mandatory fields

Let's explore if we can have cursory validation on mandatory fields within Inner Content.

This would only be for client-side validation - server-side would open a can-of-worms!

404 GetAllContentTypes when adding stacked content as new data type

Hi there,

I'm trying to add a new Data Type in Umbraco with the property editor Stacked content. When selecting "stacked content" i get the following error message.

Request error: The URL returned a 404 (not found):
/~/umbraco/backoffice/InnerContent/InnerContentApi/GetAllContentTypes

I tried uninstall Our.Umbraco.InnerContent and Our.Umbraco.StackedContent, and the reinstall them again with the same results...

Can someone please help me fix this issue?

Thanks in advance

Edge-case: Removed ContentType, existing Content

NOTE: Logging here, so I don't forget about this in future.
This is not yet an actionable task.

I've hit an edge-case with Stacked Content, where I have existing Content blocks in the stack, then later I decide to remove specific ContentType from the Stacked Content data-type configuration.

The existing Content block is still in the stack, but when I click to edit it, there is a JS console error.

The error comes from Inner Content not being able to find the corresponding ContentType for that block, see here:

https://github.com/umco/umbraco-inner-content/blob/1.1.0/src/Our.Umbraco.InnerContent/Web/UI/App_Plugins/InnerContent/js/innercontent.controllers.js#L114-L117

The practical developer says "just delete those blocks" ... but I'm wondering if we should do something nicer? Either to display a warning/notification, or let the Content block still be editable?

We can detect in the JS if the ContentType is not available after this line:

https://github.com/umco/umbraco-inner-content/blob/1.1.0/src/Our.Umbraco.InnerContent/Web/UI/App_Plugins/InnerContent/js/innercontent.controllers.js#L229

Create a Core NuGet package

So that package devs can reference the InnerContent DLL in their packages without having the App_Plugin folder restore

Courier fails if Inner-Node is empty

In my test I created a Stacked Content Data-Type, lets call it "Configuration".
In this Stacked Content you can create a Inner-Nodes that does not have any properties. Example: "Gather News articles", which is just a node with no properties. Cause that Node-Alias is giving the necessary data to the template.
When transferring this setup between environments, courier fails.

This can of course be fixed by just adding a Label to the empty Doc-Type.

Hope the issue makes sense, thanks.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.