Home > Blockchain >  How to limit calendar entry size in oracle apex
How to limit calendar entry size in oracle apex

Time:07-16

Example calendar

I was wondering if anyone knows if it's possible and how to limit a calendar entry size so it doesn't look like in the example. I don't want to span all the way to the right I want to have a fixed width as the size to the right doesn't define time as the height.

CodePudding user response:

There is no option to limit the width of calendar entry in declarative way but here is an alternate solution. Although, I wouldn't recommend limiting the width as it goes against the responsive design of Oracle APEX Theme UI.

Step 1: Update SQL Query, specifically CSS_COLUMN to have something specific to get handle of the entry. It is better than using predefined classes.

select
    1                                id,
    sysdate                          start_date,
    sysdate   1 / 24                 end_date,
    'sample text for calendar entry' task_name,
    'event-style apex-cal-green'     css_class, -- update class
    'Assigned to KD'                 as supplemental_info
from
    dual

Step 2: Enter inline CSS in page property to limit the width of calendar entry. Try to work with different property values of CSS style width if the example below does not help.

.event-style {
    width: min-content;
    /* width: 100px; */
    /* width: 20%; */
}

That's it. Final result should look like the one in the image.

enter image description here

  • Related