Friday, February 4, 2011

Aaaaaand I crashed OCAL

Yeah. I crashed Ocal. Or I think I did. The timing is too coincidental to be anything else.

I don't know how editing css would make the whole site crash, but I guess I'll find out when and if Jon or Bassel are able to upload some backups of OCAL.

OCAL CSS overhaul

List of things I've done in the css overhaul
  • changed a more than a few #px to #em
  • Updated the logo h1 css to have css applied to the logo,
  • removed h1 tag from generic css inheritance. This and the above now frees up h1 tags to be used throughout the site in a way that we can use it properly. That is, structural hierarchy and logical text placement. No more needing to guess or use text tags incorrectly with ugly styling.
  • Modified the mainnav buttons to be using em not px
  • Created a Developer Working widget, so that devs can flick it on or off to notify users that things are happening live on the site.
  • added a bullets class for uls. I originally removed the ul from css inheritance to make all ul's go back to with bullet points, but there are so many ul in use, it will take less time just to classify each ul as a bullet or not. I'm not quite sure how this will work out, or which way is easier, but I'll go with this for now.
  • adding comments to the css. It's hard to find things when you didn't originally work on the css. I'm going through and finding out what each css does, then adding comments so that other devs can see at a glance and not have to do this stupid discovery journy that I have to. I mean, I like discovering things, but I view it as unecessary time use on RE-discovering something that shouldn't have been covered up in the first place. Devs! Document your work! You don't know who is coming after you.
  • removed letter-spacing from h2
  • changed h2 font-size from 16px to 2em
  • Actually I removed a lot from h2. removed padding 0 23px 0 0, changed font-weight to bold,
  • added more stuff to the stylesheet-display. More examples on what is available to use and what they will look like with just default tags or applied classes.
  • cleaned up a lot of whitespaces that make reading the code difficult.
  • Cleaned up some Activities css and HTML. Unecessary overcoding.

New copyright violation detection!

Thanks to Richard Brett, Ocal now has the ability to detect when there is a potential copyright violation, and display a warning message.

It will activate on the tags pd_issue and potential copyright violation only so far. I'm attempting to hack it a little bit to allow a few other tags such as copyright violation - without interfering with the code in a loopback situation.

Clipart that definitly breaks copyright is hidden by librarians.  These will be tagged as copyright violation. This doesn't get the message but will proably be hidden. So only librarians will be able to see these clipart anyway.

All of the below will now get the violation message, overlaid on top of the clipart preview.

Clipart that maybe breaks copyright and needs more attention will be tagged as potential copyright violation.
Clipart that has some issue about whether it is in the public domain or eligible for CC0 will be tagged as pd_issue

I have yet to figure out how to not annoy the librarians with this toy, but maybe it will be ok. We'll see.

Edit: Strange. Librarians can't see the violation message, yet admins, regular users and anonymous browsers can. This is a good thing but it confuses me as to how I managed that. Must be something in the user settings.

Edit2: Also Strange. Some cliparts are not displaying the message even though they are tagged.

Edit3: Sigh. When styling is turned off in browser, the violation message appears at the top of EVERY clipart. All I can say to that at this stage is, don't turn your styling off. :-)