📜 ⬆️ ⬇️

We open the entry in the cohort of newsmen

The post contains a couple of suggestions for improving the design of Habr.
1. Enter the "News" checkboxes for publishers. Moreover, it is better if this flag is ticked with short news, rather than detailed reviews of the new, such as “Sublime text 3 beta” with a description of innovations.
2. Read the articles with the Translations hub as a translation .

Since the proposals do not appear soon in the implementation, or even do not appear at all, the tradition has been observed: all the proposals, if possible, are implemented in HabrAjax . There appeared news bulletins on some formal grounds.

Mark in the stream of annotations that the article is news, I wanted for a long time. But there was no tool for determining that the message is news. There are such marks for translations, educational material, topic links, but not for news.
')
Under the news should not fall news with the review. If the author has spent a lot of time reviewing or translating the review, then the category of the article becomes different - although this is news in the usual sense, but this is a complete article (or translation) in which there are much more facts for the reader. “News” is a checkbox - it should be such news that has not spent much effort in publishing; at the most - added a couple of related facts to support the topic. It is suggested not to mark news with a formal sign “a lot of text after kata” with a news flag, but only with a yellow color for the heading background.

News sites understand this difference, and there are usually different feeds for news and for reviews (examples can be remembered by everyone; similar in subject, for example, overclockers.ru : there the news column is separated from the review column, probably, from the very beginning of the site).

The news differs from the usual articles often on such a formal basis: if the text after the kata is approximately equal in volume to the text before the kata or less, then this is news. But we cannot take advantage of this feature without revealing the article. Also, there is nowhere to write down the ratings of others that this is news.

While there are no signs of news within access, we have to limit ourselves to what we have. There are a few recognized newsmen. We will collect their list fixed in the script. (The script is constantly updated at least once every 2 weeks, so updating the list is not a problem.) And you can also highlight entries that do not have a kata at all - obviously, they fall into a set on a formal basis, and the likelihood of news for such texts is high.

Here is a list of newsmen now:
'alizar,marks,aleksandrit,ilya42,FakeFactFelis,DaryaZ,mayuxi'.split(',') 


People who have several articles did not get here, some of which are news, and authors who have a small percentage of news in their list did not make it. This, of course, is not enough to identify the article as news.

If the “News” flag were entered on the site (similar to the “Training” flag), the situation would be corrected, but not 100% either: the “Translation” flags are also often forgotten, but for a different reason: change the topic to “Translation "After publication is impossible. Therefore, it is also not bad if the site script was not limited to belief in flags, but he himself marked short articles as news.

After the appearance of the signs "News" they can be used. For example, to collapse topics with the sign “News” (but not long news-reviews - this is why we need a formal selection of signs by the site along the length of the text).

Example: the newsman wrote a long and informative translation. Of course, by the formal indication that the author is a newsman, we would have lost this article in minimized. Therefore, in the userscript there is no means for folding annotations on the basis of “News”, there is no “News” checkbox , but there is only a yellow highlighting of the title and a small flag “n”.


Why yellow? It is one of the few relatively neutral pale colors that remained in the layout of the substrates. Blue (cyan) is busy translating. Green - on the topic link. Remain pink, orange, purple, yellow, gray.

By the way, about the translations. There was even a shout from the “Inner Voice”: “mark the topics as“ Translation ”, the“ Translations ”hub is not enough!”. Why not? If there is no other way to mark an article with a translation, then it is better to use possible ways than not to use anything. (A setting has already been entered in the script that marks the title in blue if there is a Translations hub.)

What are other news


Since the last publication, “ Displaying Scalable Images ” (January 22), which describes how the approach to displaying and scaling images in the script is built and a demo script (link in comments) is presented, several more functions have appeared.
  1. For images that use the wrong attribute img align = center, but which is allowed in the tag attributes of Habr articles, centering in Chrome and Opera is supported. Previously, centering was supported by user scripts and styles in Firefox, while in Chrome, Opera and Safari it was supported by site styles. Now for some reason, these styles from the site have disappeared.
    Attributes align = left, center or right can be entered in one motion: Shift + click, Ctrl + Shift + click or Ctrl + click on the button for the image tag.
  2. According to the plan for improving the layout of pure HabrAjax, the outlines of the footer are transferred from the ZenComment to it; It has become 2.5 times more compact. Removed appeared 4 links under the footer.
  3. Google cache (webcache.googleusercontent.com) also received ZenComment and HabrAjax styles and scripts. Now when you switch to it from the “404” page or “post deleted”, the styles do not change.
    An example of a page visible through Google cache (link for testing, it is also on Habré). Or ...
  4. The link to the Sandbox is extended to all submenus (it is strange that it was pushed into one of the many menu of the site).
  5. It became easier to select the comments you like and save them to the habraQuotes.ru service - with one click. Allocated from 1 to 6 comments, hovering on the context button, clicked on the "HQ" button. Comments posted on the site.
  6. It became possible to write letters to authors and commentators with quotes from their articles and comments. Suffice it to select only a quote. The author, title and design of the quote appear in the letter automatically. Under the quote in the context of the letter, it is possible to write a comment, which will also be transferred to the body of the letter.
  7. Similar to letters, by pressing the context button “Answer”, an answer to an article or comment (or question) is created for commenting.
  8. Search the site via Google and Yandex or by internal search using selection and context buttons. Results open either in a half-height frame or in a new tab (if you hold Ctrl).

Source: https://habr.com/ru/post/168147/


All Articles