Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Structured rich text element mapping #125

Open
Simply007 opened this issue Jan 5, 2021 · 10 comments
Open

Structured rich text element mapping #125

Simply007 opened this issue Jan 5, 2021 · 10 comments
Labels
enhancement groomed The issue has been groomed and should be in a good shape. help wanted

Comments

@Simply007
Copy link
Contributor

Simply007 commented Jan 5, 2021

Motivation

Allow Delivery SDK to work with Structured rich text element.

Proposed solution

  • Allow model generators to generate rich text elements differently than just a string.
  • Fill the structured rich text element model while mapping the data (.NET implementation example)

Additional context

SDK has solid support for the Thymeleaf template engine - string-based rendering of the data.
Loading data for "API" endpoints currently require parsing the HTML and create a structure for rich text on the application site.

Sample item with multilevel nested components: https://deliver.kontent.ai/306d7f21-2609-01b0-6e1c-93cbc328a82d/items/rich_text_resolution

Simple pseudocode of the structure

{
  elements: {
    content: [ // rich text element
      {
        headline: { // component/content item
          ..
        },
        section: { // component/content item
          content: [ // rich text element
            {
              headline: { // component/content item
                text: [ // rich text element
                  {
                    text: "inner headline" // text element is an object too
                  }
                ]
              }
            }
          ]
        }
      }
    ]
  }
}

Notes

  • text is also the object for interoperability with components
  • infinite loop - first version
    • log a warning and does not resolve! WITH PROPER ITEM IDENTIFICATION ERROR MESSAGE
@Simply007 Simply007 added enhancement help wanted groomed The issue has been groomed and should be in a good shape. labels Jan 5, 2021
@Olutim
Copy link

Olutim commented Oct 3, 2023

Hi @Simply007!
I've been working with Kontent-ai pretty much recently.
I browsed through the project issues tab and I found this enhancement requirement.
I would love to work on this enhancement. Could you assign me to it? Thanks!

@Simply007
Copy link
Contributor Author

Hello @Olutim,

thanks for the interest.

I am no longer the main owner of the repository, so let's pass this to @IvanKiral.

@IvanKiral
Copy link
Contributor

Hello @Olutim

Thanks for your interest in the Java SDKs. 😎

The issue has been there for some time, why do you want to be assigned there? Are you planning to work on it in the near future? Because if not, I would like to keep it open ;). However, if you would like to work on this issue or have some work done already, just submit the PR, and I will gladly do a review for the PR.

Thanks :)

@Olutim
Copy link

Olutim commented Oct 4, 2023

Hi @Simply007!
Thanks for passing my request! 🙌

@Olutim
Copy link

Olutim commented Oct 4, 2023

Hi @IvanKiral!
Thanks for your response!
Yeah, I am planning on jumping on it promptly as soon as I am assigned to it.
And I asked to be assigned to it because, I might not be able fully commit a whole day or two to it before submitting a PR. To avoid a situation where someone else would be submitting a PR after I have done some works on the issue before my PR.
I will be attending to this issue little by little progressively. But I will certainly finish it!
Thanks!✌

@IvanKiral
Copy link
Contributor

Sorry @Olutim for delayed response.

Okay I will give the assignment to you :) Have fun with the development part! I am looking forward to the PR, so please do not delay it! :D

@Olutim
Copy link

Olutim commented Oct 10, 2023

@IvanKiral
Alright!

@IvanKiral
Copy link
Contributor

Hey @Olutim. Is there any news about this issue? :)

@Olutim
Copy link

Olutim commented Nov 20, 2023

Hi @IvanKiral! Yeah, I'm still on it. I should be sending in PR very soon.

@IvanKiral
Copy link
Contributor

Great!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement groomed The issue has been groomed and should be in a good shape. help wanted
Projects
None yet
Development

No branches or pull requests

3 participants