Reason for having separate tables for slots and days - fullcalendar

In the agenda day+week view there are two separate tables for days and slots.
The days table essentially has a blank left column, x number of full height columns for each of the days with the date at the top (in a <thead> tag), and finally a right gutter with the scrollbar.
The slots table has y rows for each time slot (obviously a dynamically calculated number of rows). They have two cells per row. One for the time (12am) and one full-width cell that is only used afaik to display alternating dotted/solid horizontal borders.
My question (to the devs hopefully) is why did you make this choice, when compared to one table that contains x columns and y rows? Do you have plans to consolidate it into one table?
The reason I'm asking is because I am forking the code now to make it so that individual days+time slots are addressable (i.e. set the bgcolor on 8-10am on nov 12th to be red ... or disallow events to be dropped there).

Related

Starting grid column from half of the column

I am trying to start grid column from half of the very first column.
I tried grid-start-column with different values but it's not working. Basically, it should be like following:
grid-column: 0.5/7
I know this is not the valid code, but just for explanation I write that.
Is it possible to start a column from the half of the column?
Is it possible to start a column from the half of the column?
No. It is not.
Let's say you have a grid container with five columns and want to start spanning from halfway inside the first column (grid-column: 1.5 / 5 ). This won't work because you're not starting at a column line. More technically, the grid-row-* and grid-column-* properties accept only integers as values.
However, there is a simple workaround:
Instead of five columns use 10 columns.
Then start spanning at the third column (grid-column: 3 / 10).
This creates an equivalent layout, which looks the same visually, but with more precise control of the columns.
More details here: Changing div heights using CSS grid

CSS table text-align not working on some values in column

I have two columns, one of values for a variable and another of rankings of those values. The rankings column works fine; it is aligned left and 70% of the size of the values column. However, in the values column, all values in the column align right (as I want them to) except for the last value. The issue seems to be related to the number of characters in the value.
Here are the two columns
Any ideas?
It seems the last value is still aligning-right, but as you mentioned with the increased values in the left column it is pushing them together. If you are able, increasing the overall size of the column to account for increased values. (e.g. increase column padding and/or width).

How to create descending left hand row numbers in a table (tr) with CSS

I use the method shown hear;
https://kryogenix.org/code/browser/sorttable/#lefthandheader
to add numbers to the left hand side of my table. And it works great by putting 1 at the top on the first row, 2 on the second and so on. However my table is time sensitive, and descending in order so the top row is actually the most current thing that occurred. I would like the left column to reflect that by having the highest number on top and descending to the bottom where the first event occurred.
Is there a simple way to modify the CSS to do this?
My table in question is built using PHP/MYSql. It turns out that the quoted solution to number the left hand column has at least on option, you can add an option to the CSS like this.
table.sortable tbody {
counter-reset: sortabletablescope 48;
}
Then reference it as demonstrated here: https://jsbin.com/yanihid/edit
The result is exactly as I needed it. Counting the rows starting at the highest number. All you have to do is know the count, an easy deal with PHP/MYSQL.

Best way to represent 3 dimensional data in sqlite table?

I was wondering if there is a nice way to represent a three dimensional table in sqlite. i.e. how to create a table in sqlite with a 3rd dimension: e.g.: col, row, and height?
In my case, number of columns would be fixed, but rows and height will grow on demand by inserting.
If possible, how does one SELECT a specific height on a specific row?

Bootstrap 3.1 - How to have list item text line up on the left, AND centered in column

Not sure how to describe this exactly but here goes:
I have a 3 column design, and there is a list of items in each of the columns.
I need to have:
1) Each column's list items must aligned so that the left side of each word lines up
2) Each list itself must be centered within its column. (This of course means that list items on their own won't necessarily be dead center inside their respective column)
I would prefer a CSS solution without javascript/jQuery.
I have an example of bootstrap code that I am working on here to help explain what doesn't work for me:
http://bootply.com/112003
The first row is what happens when the text is centered within each column. Condition 2 passes, condition 1 fails.
The second row is what happens when I divide up each of the three colums into 3 subcolumns. Condition 1 passes, but condition 2 fails. This is subtle. While each list item is in the center subcolumn, overall the list isn't in the dead center of that column. (Imagine the list is one item if that helps think about the problem.)
Thanks to anyone who can try to help me out. This one is driving me a little bit crazy :)

Resources