live627

  • Should five per cent appear too small / Be thankful I don't take it all / 'Cause I'm the taxman, yeah I'm the taxman
  • Messages: 1 670
Wand
« le 15 Juillet 2012 à 05:34 »
This is another of my plugins for developers. This populates the database with dummy entries.

  • 10 categories
  • 100 boards
  • 150,000 members
  • 270,000 topics
  • 3,000,000 messages

Based on SlammedDime's script. Which also generates lipsum text.

A confident man keeps quiet.whereas a frightened man keeps talking, hiding his fear.

Nao

  • Dadman with a boy
  • Messages: 16 082
Re: Wand
« Réponse #1, le 15 Juillet 2012 à 07:28 »
That progress bar reminds me of somethin'... :P

live627

  • Should five per cent appear too small / Be thankful I don't take it all / 'Cause I'm the taxman, yeah I'm the taxman
  • Messages: 1 670
Re: Wand
« Réponse #2, le 15 Juillet 2012 à 07:45 »
What is it?

Arantor

  • As powerful as possible, as complex as necessary.
  • Messages: 14 278
Re: Wand
« Réponse #3, le 15 Juillet 2012 à 15:20 »
The style submitted to SMF by Nas ;)
When we unite against a common enemy that attacks our ethos, it nurtures group solidarity. Trolls are sensational, yes, but we keep everyone honest. | Game Memorial

live627

  • Should five per cent appear too small / Be thankful I don't take it all / 'Cause I'm the taxman, yeah I'm the taxman
  • Messages: 1 670
Re: Wand
« Réponse #4, le 15 Juillet 2012 à 23:27 »
Oh, er, yes, it is. That's how I found that keyframes  won't work in WeCSS.

I also put in time remaining estimates, but they are horribly inaccurate/unreliable. They keep jumping from one number to the next.

Arantor

  • As powerful as possible, as complex as necessary.
  • Messages: 14 278
Re: Wand
« Réponse #5, le 15 Juillet 2012 à 23:38 »
Probably because all the @ constructs in CSS generally are fall into the same general traps as things like the HTML5 audio/video tags, designed by people who have little idea how people would actually want to use these things and base it on what they think people might like.

Keyframes is a great idea, but it's not even standard CSS yet, it's solely in @-moz-keyframes and @-webkit-keyframes constructs, which I didn't even think were legal.

live627

  • Should five per cent appear too small / Be thankful I don't take it all / 'Cause I'm the taxman, yeah I'm the taxman
  • Messages: 1 670
Re: Wand
« Réponse #6, le 15 Juillet 2012 à 23:55 »
I thought the braces {} did it.

Arantor

  • As powerful as possible, as complex as necessary.
  • Messages: 14 278
Re: Wand
« Réponse #7, le 16 Juillet 2012 à 00:16 »
Nope. There's quite a bit to it really.

Firstly you have to declare the animation.

Code: [Sélectionner]
@keyframes myanim
{
  from: { top: 0px}
  to: { top: 100px }
}

(or @-moz-keyframes or @-webkit-keyframes for now)

Then tell the relevant item to use it:
Code: [Sélectionner]
#mydiv
{
  animation: myanim 5s infinite
}

I can't imagine anything that would specifically upset WeCSS in this, and honestly if it were reformatted to use normal WeCSS layout it should work just fine.

Nao

  • Dadman with a boy
  • Messages: 16 082
Re: Wand
« Réponse #8, le 16 Juillet 2012 à 10:56 »
Citation de live627 le 15 Juillet 2012 à 07:45
What is it?
That:
http://wedge.org/do/media/?sa=stats

@Pete> What style by Nas? The thing I'm talking about was cooked up by Dragooon for AeMe...
Posté : 16 Juillet 2012 à 10:53
Citation de live627 le 15 Juillet 2012 à 23:27
Oh, er, yes, it is.
It is... What?
Citation
That's how I found that keyframes  won't work in WeCSS.
And... did you bother to report that...? I don't remember hearing about that.

Did you try putting keyframes into a separate CSS file using the regular CSS syntax? Just to know if it's a parsing issue or something else...

Arantor

  • As powerful as possible, as complex as necessary.
  • Messages: 14 278
Re: Wand
« Réponse #9, le 16 Juillet 2012 à 14:46 »
Citation
@Pete> What style by Nas? The thing I'm talking about was cooked up by Dragooon for AeMe...
I can't seem to find it anywhere but basically Nas redesigned the progress bar on the installer, I don't know if it was pushed to the main repo, but it was submitted IIRC. But it basically looks like the progress bars in this plugin - not the same as the stats page.
Citation
And... did you bother to report that...? I don't remember hearing about that.
I think it was mentioned in passing once, but given the above it's possible that it's not being used properly.

Nao

  • Dadman with a boy
  • Messages: 16 082
Re: Wand
« Réponse #10, le 16 Juillet 2012 à 17:00 »
Okay, found it... I think.
https://github.com/SimpleMachines/SMF2.1/pull/59
I can't see it in action, so I have no idea what it looks like. But it reminds me of Dragooon's bars because they're skewed by 45°.

As for keyframes, I did a bit of testing and here's what I came up with:

Code: [Sélectionner]
.cat
-prefix-animation-duration: 3s
-prefix-animation-name: slidein

@-prefix-keyframes slidein
from
margin-left: 100%
width: 300%
to
margin-left: 0%
width: 100%

This works just fine...
What's your problematic code then?

Arantor

  • As powerful as possible, as complex as necessary.
  • Messages: 14 278
Re: Wand
« Réponse #11, le 16 Juillet 2012 à 17:39 »
Citation
I can't see it in action, so I have no idea what it looks like. But it reminds me of Dragooon's bars because they're skewed by 45°.
There are screenshots taken there, and that's exactly what I had in mind.

Nao

  • Dadman with a boy
  • Messages: 16 082
Re: Wand
« Réponse #12, le 16 Juillet 2012 à 18:42 »
Yep, but I just can't bother to download Nas's repo and install it just to watch that... :P
I'm sure it looks good, too. Hey, if it's SMF 2.1 then we can happily steal from it :lol: I'm sure he'd be glad, too.
Although for now I'd rather use a <progress> bar, I'm sure in the future I'll want to harmonize its looks.

Dragooon

  • I can code! Really!
  • polygon.com has to be one of the best sites I've seen recently.
  • Messages: 1 841
The way it's meant to be

Nao

  • Dadman with a boy
  • Messages: 16 082
Re: Wand
« Réponse #14, le 25 Juillet 2012 à 19:20 »
Citation de Arantor le 16 Juillet 2012 à 00:16
I can't imagine anything that would specifically upset WeCSS in this, and honestly if it were reformatted to use normal WeCSS layout it should work just fine.
I had a look at Nas' code... I think I found it. His keyframes use 0% and 100% instead of 'from' and 'to'.
Because of that, they fail to be compiled by Wedge because rules are expected to NOT start with a digit.
So I had a choice between (1) only accepting digits when inside a keyframe (which forces me to change the way I parse the file), or (2) accepting digits. I chose (2) because I'm fucking lazy. It works now.

Although the CSS is quite large for something so small, I like it overall.
Posté : 16 Juillet 2012 à 22:05

Was wondering... I haven't yet committed my changes to Class-CSS on this, because it feels 'wrong' to accept digits in my regex when normally they're not allowed at the beginning of a selector. (Except, as pointed out, in keyframe definitions.)
Should I just deal with it and add support...?