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

Tutorial 13 - margins / paddings ? #617

Closed
aviriel opened this issue Oct 18, 2015 · 15 comments
Closed

Tutorial 13 - margins / paddings ? #617

aviriel opened this issue Oct 18, 2015 · 15 comments

Comments

@aviriel
Copy link
Contributor

aviriel commented Oct 18, 2015

I followed the Tutorial 1-13. It's awesome and gives an opportunity to start working with Aikau. Thank you very much.

But I met one bug (yeh, only one) that I cannot fix. After moving the table with groups to the HorizontalWidgets -> ClassicWindow, the table does not fit the widget. I removed all "widthPc" configurations and I use MacBook, so the width of the screen for websites is 1280px.

selection_047

As I understand, the problem is that the name of the groups are too long. You had the same default groups in the table in the tutorial (like ALFRESCO_MODEL_ADMINISTRATORS) and the length of the text in the cells was ok for your screen. So the question is:
Is it normal behaviour of the nesting widgets? So if the table is bigger than a block (ClassicWindow), then users will have the same bug that I have? Or is it a way to solve this?

@draperd
Copy link

draperd commented Oct 19, 2015

Thanks the feedback - it's greatly appreciated and I'm glad you've found the tutorial useful.

With regards to the width, since Aikau 1.0.31 it is now possible to configure a "maxWidth" attribute on the alfresco/renderers/Property (and therefore any widgets that inherit from it) that can be used to apply an ellipsis to long values (see http://dev.alfresco.com/resource/docs/aikau-jsdoc/Property.html).

This won't happen automatically unfortunately (i.e. it won't automatically detect when a value is too long) so you'll need to configure a value.

However, you're probably right that the ClassicWindow should use scrollbars on overflow (or should be configured to do so). I'll raise a bug to get that fixed.

Thanks again.

@draperd
Copy link

draperd commented Oct 19, 2015

I've raised https://issues.alfresco.com/jira/browse/AKU-644 and it's in the provisional plan for inclusion in our next sprint.

@aviriel
Copy link
Contributor Author

aviriel commented Oct 19, 2015

Thank you!
Then I want to add here info about one more "bug" in the tutorial:
Tutorial16, step 5. It does not work without adding "strict: false" to the visibility config. If it's an expected behaviour, then can you update the tutorial?

@draperd
Copy link

draperd commented Oct 19, 2015

I think that would be an error in the tutorial - it's possible that the tutorial chapter was written before the changes mentioned here (https://www.alfresco.com/blogs/developer/2014/10/28/aikau-updates-to-dynamic-visibility-config/) ... I'll raise another issue to review and update that tutorial chapter as necessary.

@draperd
Copy link

draperd commented Oct 19, 2015

I've raised https://issues.alfresco.com/jira/browse/AKU-645 to cover the tutorial investigation/correction.

@draperd
Copy link

draperd commented Oct 20, 2015

Can you elaborate a bit more on what you think is going wrong with Tutorial 16, step 5... I've tested it out on the latest version of Aikau and it works fine without the strict: false being applied.

The behaviour I'm seeing is that the text field is not initially visible (which is correct) but if you check the checkbox it becomes visible.

Can you describe the behaviour that you're seeing please?

@aviriel
Copy link
Contributor Author

aviriel commented Oct 20, 2015

Tried it again by removing strict:false, and now it works. Sorry for this. I don't know what changed.

@draperd
Copy link

draperd commented Oct 20, 2015

No problem - thanks for checking again for me... I'm just glad it's working :)

@aviriel
Copy link
Contributor Author

aviriel commented Oct 20, 2015

Then one more question from my side. I know that I become annoying, I don't know is it a problem in a Tutorial or I'm not right again. I owe you a beer in Brussels in April if you'll not ban me because of all my issues :)

Tutorial 17. Step 5
After step 4 I can preview DOCX, PNG, XLS etc, but not PDF ("It has not been possible to load the PDF file"). After adding itemProperty: "", in the beginning of Step 5 I can preview PDF too.

But if I replace:

{
  name: "alfresco/renderers/PropertyLink",
  config: {
    propertyToRender: "node.properties.cm:name",
    publishTopic: "ALF_RETRIEVE_SINGLE_DOCUMENT_REQUEST",
    publishPayloadType: "PROCESS",
    useCurrentItemAsPayload: false,
    publishPayloadModifiers: ["processCurrentItemTokens"],
    publishPayload: {
      nodeRef: "{node.nodeRef}",
      rawData: true
    },                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         
    renderFilter: [
      {
        property: "node.isContainer",
        values: [false]
      }
    ]
  }
}

with

{
  name: "alfresco/renderers/PropertyLink",
  config: {
    propertyToRender: "node.properties.cm:name",
    publishTopic: "ALF_RETRIEVE_SINGLE_DOCUMENT_REQUEST_SUCCESS",
    renderFilter: [
       {
          property: "node.isContainer",
          values: [false]
       }
    ]
  }
}

window with PDFJS disappears.

@draperd
Copy link

draperd commented Oct 21, 2015

It's no problem answering questions - I'm always very happy to help people as it's useful to understand where there are gaps in the educational material available.

I'll have to step through the tutorial again with the latest version of Aikau to see if anything's changed... I can't see anything obviously wrong, but maybe we've inadvertently introduced a bug - I'll try and get to that later this week.

@aviriel
Copy link
Contributor Author

aviriel commented Oct 21, 2015

Ok, thank you! I met this on Aikau 1.0.39, I started the Tutorial a week ago. I'll try to update to the latest version.

@draperd
Copy link

draperd commented Oct 21, 2015

If you're on 1.0.39 you should be fine... I meant that we might have broken it since the tutorial was written.

@draperd
Copy link

draperd commented Oct 26, 2015

You're absolutely right... I've investigated the issue and we appear to have regressed the capabilities of AlfDocument in AKU-233. This has been broken since 1.0.14.

I've raised https://issues.alfresco.com/jira/browse/AKU-656 to address the issue and it will be fixed in the 1.0.42 release. We will add a new unit test to prevent any future regressions.

Thanks for finding this for us.

@aviriel
Copy link
Contributor Author

aviriel commented Oct 26, 2015

Then I completed the Tutorial and don't have any other problems :) You may close the issue.

@draperd
Copy link

draperd commented Nov 4, 2015

All issues reported in this thread have now been addressed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants